10 references to ExceptionAssert2
Microsoft.AspNetCore.DataProtection.Tests (10)
KeyManagement\KeyRingBasedDataProtectorTests.cs (10)
135var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Protect(new byte[0])); 167var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(badProtectedPayload)); 185var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(badProtectedPayload)); 203var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(badProtectedPayload)); 234var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(protectedData)); 287var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(protectedData)); 323var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(protectedData)); 421var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(protectedData)); 762var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(shortCiphertext, ref destination)); 783var ex = ExceptionAssert2.ThrowsCryptographicException(() => protector.Unprotect(new byte[10], ref buffer));