コード例 #1
0
        public void GetErrorMessage_ThrowsOnUnkownCode()
        {
            foreach (var error in Enum.GetValues <UnixError>())
            {
                Assert.False(string.IsNullOrEmpty(UnixMarshal.GetErrorMessage(error)));
            }

            Assert.Equal("An Unix error occurred. Error code: 1234", UnixMarshal.GetErrorMessage((UnixError)1234));
        }