Unit Test "ShouldNotReferenceThisAsGlobalScopeInDetachedFunctionInStrictMode" failed

Dec 19, 2012 at 4:15 PM

I downloaded the latest source (May 2012), plus the latest Antlr3 (version, built the whole solution with Viisual Studio 2010 and .NET 4.0 Client Profile.

When I ran the Unit Tests (Jint.Tests), all of Unit Tests passed except for ShouldNotReferenceThisAsGlobalScopeInDetachedFunctionInStrictMode. It failed on the statement [ assert(1, getx()); ] because getx() returns null (it should return 1).

It appears that his Unit Test has been added after the last release. What would be the cause to this failure? It seems the global 'this' was not found.

FYI: Migrating JINT to VS2010 and .NET 4 invloves resolving ambiguous Func<> delegates (by changing to either System.Func<> or Jint.Delegates.Func<>).