SERVER-137590ClosedWon't Do

Restructure unit tests to avoid multiple ScriptEngines

Currently scripting_legacy_mozjs_test tears down and recreates a mozjs ScriptEngine multiple times in the same process (once for each test case). This is not a supported pattern by SpiderMonkey, and it requires custom changes to the SpiderMonkey code to make it work - in the existing integration and for the ESR 153 upgrade. This is error-prone and difficult to maintain, as each custom SpiderMonkey change carries a risk of introducing unintended side-effects, and each SpiderMonkey upgrade coul

Affected Versions
Versions known to exhibit this issue

No affected versions recorded.

Fixed Versions
Versions that include the fix

No fix available yet.

Components
Server components related to this issue

No components specified.

Labels
Tags and classification

No labels assigned.