Skip to content

Commit 1eb8501

Browse files
committed
Improve test to call enum in another assembly
- Now enum type is actually used in a local variable and not just the value.
1 parent 5a879b6 commit 1eb8501

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

MetadataProcessor.Tests/TestNFApp/TestEnumInAnotherAssembly.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,11 @@ public void CallTestEnumInAnotherAssembly()
1111
{
1212
// This test checks if MDP can minimize the assembly using an enum that is defined in another assembly
1313
// and the class calling it is in a different assembly BUT in the same namespace.
14-
var ioException = new IOException(
14+
IOException.IOExceptionErrorCode dummyEnum = IOException.IOExceptionErrorCode.DirectoryNotFound;
15+
16+
_ = new IOException(
1517
string.Empty,
16-
(int)IOException.IOExceptionErrorCode.DirectoryNotFound);
18+
(int)dummyEnum);
1719
}
1820
}
19-
2021
}

0 commit comments

Comments
 (0)