mirror of
https://github.com/opensim/opensim.git
synced 2026-08-04 16:22:50 +08:00
Add lsl event arg checking for at_rot_target
This commit is contained in:
@@ -260,6 +260,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
|
||||
TestVectorArgEvent("land_collision_end");
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void TestAtRotTargetEvent()
|
||||
{
|
||||
TestHelpers.InMethod();
|
||||
// TestHelpers.EnableLogging();
|
||||
|
||||
TestIntRotRotArgEvent("at_rot_target");
|
||||
}
|
||||
|
||||
private void TestIntArgEvent(string eventName)
|
||||
{
|
||||
@@ -285,6 +293,14 @@ namespace OpenSim.Region.ScriptEngine.Shared.Tests
|
||||
TestCompile("default { " + eventName + "(vector v, vector w) {{}} }", true);
|
||||
}
|
||||
|
||||
private void TestIntRotRotArgEvent(string eventName)
|
||||
{
|
||||
TestCompile("default { " + eventName + "(integer n, rotation r, rotation s) {} }", false);
|
||||
TestCompile("default { " + eventName + "{{}} }", true);
|
||||
TestCompile("default { " + eventName + "(string s) {{}} }", true);
|
||||
TestCompile("default { " + eventName + "(integer n, rotation r, rotation s, rotation t) {{}} }", true);
|
||||
}
|
||||
|
||||
private void TestCompile(string script, bool expectException)
|
||||
{
|
||||
bool gotException = false;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user