Testing dotnetproxyagent and Oaa2JavaNet.dll

A number of sample applications are provided in the directory src/samples_dotnet. To build these applications, navigate to this directory and execute "ant". Alternatively, the project solution files can be opened in MS Visual Studio .NET 2003 and built from there. Note also that prebuilt versions of the dotnet sample agents can be found in the directory "runtime/samples_dotnet". Before executing these agents, the .NET runtime version 1.1 must be installed, which can be obtained from Miscrosoft's web site.

After building the sample applications, run the dotnetproxyagent as described in running-dotnetproxyagent.html. Then, make sure "setup.pl" is set correctly according to the OAA2 installation instructions. Finally, on the same machine where the dotnetproxyagent is run from, execute "src/samples_dotnet/AddAgent/bin/Release/AddAgent.exe" (or "runtime/samples_dotnet/AddAgent/bin/Release/AddAgent.exe"). Shortly after executing AddAgent.exe, the output for dotnetproxyagent should look like:

    Listening on port 4016 for client connections
    Accepted client connection from /127.0.0.1
    Created bean 0, bean class = com.sri.oaa2.javanetbridge.Oaa2JavaNet
    Accepted client connection from /127.0.0.1
    OAA2 Java library Release : 2.2
    Connected to tcp(Host,Port)
    Ready.
The output for AddAgent.exe should look like:
    csharp_addAgent: Connection Made
    csharp_addAgent: Registering csharp_addAgent
Next, launch the debug agent and execute the solvable: "oaa_Solve(add(1,2,Sum),[])". The answer should come back as "add(1,2,3)", and AddAgent.exe should display something like:
    csharp_addAgent: doOAAEvent called, goal = add(1,2,_5943)
If this test works, then the .NET library is working.

To completely test the .NET library, TestAgent has been ported to csharp. TestAgent is an agent that runs in unison with the Java unit tests and direct connect timing code. See "src/oaalib/java/test/README.txt" for information on how to run the unit tests and timing code. Instead of running the Java TestAgent, the csharp TestAgent can be run. This agent can be found in "src/samples_dotnet/TestAgent" (or the prebuilt binary in "runtime/samples_dotnet/TestAgent").