PageRenderTime 25ms CodeModel.GetById 19ms app.highlight 3ms RepoModel.GetById 1ms app.codeStats 0ms

/tags/rel-1-3-29/SWIG/Examples/test-suite/csharp/constover_runme.cs

#
C# | 34 lines | 27 code | 7 blank | 0 comment | 12 complexity | a24259147695c91c89fd144fb04008cc MD5 | raw file
Possible License(s): LGPL-2.1, Cube, GPL-3.0, 0BSD, GPL-2.0
 1using System;
 2using constoverNamespace;
 3
 4public class runme
 5{
 6    static void Main() 
 7    {
 8        string p = constover.test("test");
 9        if ( p != "test" )
10            throw new Exception( "test failed!" );
11
12        p = constover.test_pconst("test");
13        if ( p != "test_pconst" )
14            throw new Exception( "test_pconst failed!" );
15
16        Foo f = new Foo();
17        p = f.test("test");
18        if ( p != "test" )
19            throw new Exception( "member-test failed!" );
20
21        p = f.test_pconst("test");
22        if ( p != "test_pconst" )
23            throw new Exception( "member-test_pconst failed!" );
24
25        p = f.test_constm("test");
26        if ( p != "test_constmethod" )
27            throw new Exception( "member-test_constm failed!" );
28
29        p = f.test_pconstm("test");
30        if ( p != "test_pconstmethod" )
31            throw new Exception( "member-test_pconstm failed!" );
32    }
33}
34