aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/ScriptEngine/Shared/CodeTools
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2013-11-16 02:58:06 +0000
committerJustin Clark-Casey (justincc)2013-11-16 02:58:06 +0000
commitec4d96acc9f6fe63cbf8666f0fd946d483b90111 (patch)
tree982b7bd426f5f80a764b858973b816c1a2a1995f /OpenSim/Region/ScriptEngine/Shared/CodeTools
parentIf anything other than a single integer is specified for events that only tak... (diff)
downloadopensim-SC_OLD-ec4d96acc9f6fe63cbf8666f0fd946d483b90111.zip
opensim-SC_OLD-ec4d96acc9f6fe63cbf8666f0fd946d483b90111.tar.gz
opensim-SC_OLD-ec4d96acc9f6fe63cbf8666f0fd946d483b90111.tar.bz2
opensim-SC_OLD-ec4d96acc9f6fe63cbf8666f0fd946d483b90111.tar.xz
refactor common code out of no argument LSL event regression tests
Diffstat (limited to 'OpenSim/Region/ScriptEngine/Shared/CodeTools')
-rw-r--r--OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/LSL_EventTests.cs27
1 files changed, 13 insertions, 14 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/LSL_EventTests.cs b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/LSL_EventTests.cs
index 42d2d7b..ccfc04e 100644
--- a/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/LSL_EventTests.cs
+++ b/OpenSim/Region/ScriptEngine/Shared/CodeTools/Tests/LSL_EventTests.cs
@@ -44,8 +44,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
44 TestHelpers.InMethod(); 44 TestHelpers.InMethod();
45// TestHelpers.EnableLogging(); 45// TestHelpers.EnableLogging();
46 46
47 TestCompile("default { moving_end() {} }", false); 47 TestVoidArgEvent("moving_end");
48 TestCompile("default { moving_end(integer n) {} }", true);
49 } 48 }
50 49
51 [Test] 50 [Test]
@@ -54,8 +53,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
54 TestHelpers.InMethod(); 53 TestHelpers.InMethod();
55// TestHelpers.EnableLogging(); 54// TestHelpers.EnableLogging();
56 55
57 TestCompile("default { moving_start() {} }", false); 56 TestVoidArgEvent("moving_start");
58 TestCompile("default { moving_start(integer n) {} }", true);
59 } 57 }
60 58
61 [Test] 59 [Test]
@@ -64,8 +62,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
64 TestHelpers.InMethod(); 62 TestHelpers.InMethod();
65// TestHelpers.EnableLogging(); 63// TestHelpers.EnableLogging();
66 64
67 TestCompile("default { not_at_rot_target() {} }", false); 65 TestVoidArgEvent("not_at_rot_target");
68 TestCompile("default { not_at_rot_target(integer n) {} }", true);
69 } 66 }
70 67
71 [Test] 68 [Test]
@@ -74,8 +71,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
74 TestHelpers.InMethod(); 71 TestHelpers.InMethod();
75// TestHelpers.EnableLogging(); 72// TestHelpers.EnableLogging();
76 73
77 TestCompile("default { not_at_target() {} }", false); 74 TestVoidArgEvent("not_at_target");
78 TestCompile("default { not_at_target(integer n) {} }", true);
79 } 75 }
80 76
81 [Test] 77 [Test]
@@ -84,8 +80,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
84 TestHelpers.InMethod(); 80 TestHelpers.InMethod();
85// TestHelpers.EnableLogging(); 81// TestHelpers.EnableLogging();
86 82
87 TestCompile("default { state_entry() {} }", false); 83 TestVoidArgEvent("state_entry");
88 TestCompile("default { state_entry(integer n) {} }", true);
89 } 84 }
90 85
91 [Test] 86 [Test]
@@ -94,8 +89,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
94 TestHelpers.InMethod(); 89 TestHelpers.InMethod();
95// TestHelpers.EnableLogging(); 90// TestHelpers.EnableLogging();
96 91
97 TestCompile("default { state_exit() {} }", false); 92 TestVoidArgEvent("state_exit");
98 TestCompile("default { state_exit(integer n) {} }", true);
99 } 93 }
100 94
101 [Test] 95 [Test]
@@ -104,8 +98,13 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
104 TestHelpers.InMethod(); 98 TestHelpers.InMethod();
105// TestHelpers.EnableLogging(); 99// TestHelpers.EnableLogging();
106 100
107 TestCompile("default { timer() {} }", false); 101 TestVoidArgEvent("timer");
108 TestCompile("default { timer(integer n) {} }", true); 102 }
103
104 private void TestVoidArgEvent(string eventName)
105 {
106 TestCompile("default { " + eventName + "() {} }", false);
107 TestCompile("default { " + eventName + "(integer n) {} }", true);
109 } 108 }
110 109
111 [Test] 110 [Test]