Comment out regression TestJsonTestPath and TestJsonTestPathJson as these will go away soon

user_profiles
Justin Clark-Casey (justincc) 2013-02-15 00:32:20 +00:00
parent 30a60d661f
commit 0b2608d8f4
1 changed files with 62 additions and 62 deletions

View File

@ -335,69 +335,69 @@ namespace OpenSim.Region.OptionalModules.Scripting.JsonStore.Tests
} }
} }
[Test] // [Test]
public void TestJsonTestPath() // public void TestJsonTestPath()
{ // {
TestHelpers.InMethod(); // TestHelpers.InMethod();
// TestHelpers.EnableLogging(); //// TestHelpers.EnableLogging();
//
// UUID storeId = (UUID)InvokeOp("JsonCreateStore", "{ 'Hello' : { 'World' : 'One' } }");
//
// {
// int result = (int)InvokeOp("JsonTestPath", storeId, "Hello.World");
// Assert.That(result, Is.EqualTo(1));
// }
//
// // Test for path which does not resolve to a value.
// {
// int result = (int)InvokeOp("JsonTestPath", storeId, "Hello");
// Assert.That(result, Is.EqualTo(0));
// }
//
// {
// int result2 = (int)InvokeOp("JsonTestPath", storeId, "foo");
// Assert.That(result2, Is.EqualTo(0));
// }
//
// // Test with fake store
// {
// UUID fakeStoreId = TestHelpers.ParseTail(0x500);
// int fakeStoreValueRemove = (int)InvokeOp("JsonTestPath", fakeStoreId, "Hello");
// Assert.That(fakeStoreValueRemove, Is.EqualTo(0));
// }
// }
UUID storeId = (UUID)InvokeOp("JsonCreateStore", "{ 'Hello' : { 'World' : 'One' } }"); // [Test]
// public void TestJsonTestPathJson()
{ // {
int result = (int)InvokeOp("JsonTestPath", storeId, "Hello.World"); // TestHelpers.InMethod();
Assert.That(result, Is.EqualTo(1)); //// TestHelpers.EnableLogging();
} //
// UUID storeId = (UUID)InvokeOp("JsonCreateStore", "{ 'Hello' : { 'World' : 'One' } }");
// Test for path which does not resolve to a value. //
{ // {
int result = (int)InvokeOp("JsonTestPath", storeId, "Hello"); // int result = (int)InvokeOp("JsonTestPathJson", storeId, "Hello.World");
Assert.That(result, Is.EqualTo(0)); // Assert.That(result, Is.EqualTo(1));
} // }
//
{ // // Test for path which does not resolve to a value.
int result2 = (int)InvokeOp("JsonTestPath", storeId, "foo"); // {
Assert.That(result2, Is.EqualTo(0)); // int result = (int)InvokeOp("JsonTestPathJson", storeId, "Hello");
} // Assert.That(result, Is.EqualTo(1));
// }
// Test with fake store //
{ // {
UUID fakeStoreId = TestHelpers.ParseTail(0x500); // int result2 = (int)InvokeOp("JsonTestPathJson", storeId, "foo");
int fakeStoreValueRemove = (int)InvokeOp("JsonTestPath", fakeStoreId, "Hello"); // Assert.That(result2, Is.EqualTo(0));
Assert.That(fakeStoreValueRemove, Is.EqualTo(0)); // }
} //
} // // Test with fake store
// {
[Test] // UUID fakeStoreId = TestHelpers.ParseTail(0x500);
public void TestJsonTestPathJson() // int fakeStoreValueRemove = (int)InvokeOp("JsonTestPathJson", fakeStoreId, "Hello");
{ // Assert.That(fakeStoreValueRemove, Is.EqualTo(0));
TestHelpers.InMethod(); // }
// TestHelpers.EnableLogging(); // }
UUID storeId = (UUID)InvokeOp("JsonCreateStore", "{ 'Hello' : { 'World' : 'One' } }");
{
int result = (int)InvokeOp("JsonTestPathJson", storeId, "Hello.World");
Assert.That(result, Is.EqualTo(1));
}
// Test for path which does not resolve to a value.
{
int result = (int)InvokeOp("JsonTestPathJson", storeId, "Hello");
Assert.That(result, Is.EqualTo(1));
}
{
int result2 = (int)InvokeOp("JsonTestPathJson", storeId, "foo");
Assert.That(result2, Is.EqualTo(0));
}
// Test with fake store
{
UUID fakeStoreId = TestHelpers.ParseTail(0x500);
int fakeStoreValueRemove = (int)InvokeOp("JsonTestPathJson", fakeStoreId, "Hello");
Assert.That(fakeStoreValueRemove, Is.EqualTo(0));
}
}
[Test] [Test]
public void TestGetArrayLength() public void TestGetArrayLength()