Skip to content

Commit

Permalink
Fixed cleanup in unit test DynamicScopeTest
Browse files Browse the repository at this point in the history
Co-authored-by: Satish Srinivasan <[email protected]>
  • Loading branch information
2 people authored and gbrail committed Nov 28, 2024
1 parent c915727 commit 83f2b81
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertSame;

import org.junit.After;
import org.junit.Test;
import org.mozilla.javascript.Context;
import org.mozilla.javascript.ContextFactory;
Expand Down Expand Up @@ -49,6 +50,13 @@ public FreshContext(ContextFactory contextFactory) {
}
}

@After
public void tearDown() throws Exception {
while (Context.getCurrentContext() != null) {
Context.exit();
}
}

@Test
/** Sealed standard objects vs dynamic scopes. */
public void initStandardObjectsSealed() {
Expand Down

0 comments on commit 83f2b81

Please sign in to comment.