CK.Text.Tests.StringMatcherTests.matching_double_values C# (CSharp) Method

matching_double_values() private method

private matching_double_values ( string s, double d ) : void
s string
d double
return void
        public void matching_double_values( string s, double d )
        {
            StringMatcher m = new StringMatcher( "P" + s + "S" );
            Assert.That( m.MatchChar( 'P' ) );
            int idx = m.StartIndex;
            Assert.That( m.TryMatchDoubleValue() );
            m.UncheckedMove( idx - m.StartIndex );
            double parsed;
            Assert.That( m.TryMatchDoubleValue( out parsed ) );
            Assert.That( parsed, Is.EqualTo( d ).Within( 1 ).Ulps );
            Assert.That( m.MatchChar( 'S' ) );
            Assert.That( m.IsEnd );
        }