aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs29
1 files changed, 29 insertions, 0 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs
index 02108c7..e00acc9 100644
--- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/CSCodeGeneratorTest.cs
@@ -369,6 +369,35 @@ default
369 } 369 }
370 370
371 [Test] 371 [Test]
372 public void TestCStyleComments()
373 {
374 string input = @"/* this test tests comments
375 of the C variety
376*/
377default
378{
379 touch_start(integer num_detected) /* this should be stripped */
380 {
381 /*
382 * fill
383 * in
384 * code
385 * here...
386 */
387 }
388}
389";
390 string expected =
391 "\n public void default_event_touch_start(LSL_Types.LSLInteger num_detected)" +
392 "\n {" +
393 "\n }\n";
394
395 CSCodeGenerator cg = new CSCodeGenerator();
396 string output = cg.Convert(input);
397 Assert.AreEqual(expected, output);
398 }
399
400 [Test]
372 public void TestGlobalDefinedFunctions() 401 public void TestGlobalDefinedFunctions()
373 { 402 {
374 string input = @"// this test tests custom defined functions 403 string input = @"// this test tests custom defined functions