Ejemplo n.º 1
0
        public void Match_should_convert_the_underlying_exception_to_R()
        {
            Exceptional <int> data = new InvalidOperationException("error");

            var result = data.Match(
                ex => ex.Message,
                d => d.ToString()
                );

            result.Should().BeOfType <string>();
            result.Should().Be("error");
        }