Skip to content

Commit 36313d7

Browse files
committed
Be less picky about exception types when commands fail
1 parent bc571f5 commit 36313d7

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

test/SeqCli.Tests/Config/ExternalDataProtectorTests.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,8 @@ public void IfEncryptorDoesNotExistEncryptThrows()
2222
public void IfEncryptorFailsEncryptThrows()
2323
{
2424
var protector = new ExternalDataProtector("bash", "-c \"exit 1\"", Some.String(), null);
25-
Assert.Throws<Exception>(() => protector.Encrypt(Some.Bytes(200)));
25+
// May be `Exception` or `IOException`.
26+
Assert.ThrowsAny<Exception>(() => protector.Encrypt(Some.Bytes(200)));
2627
}
2728

2829
[Fact]

0 commit comments

Comments
 (0)