Skip to content

Commit

Permalink
commit changes missing from last refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
rbri committed Jan 7, 2025
1 parent 56674ea commit 25b30bf
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class StrictModeApiTest {
@Test
public void strictModeError() {
final ContextFactory contextFactory =
new Utils.FeatureContextFactory(
Utils.contextFactoryWithFeatures(
Context.FEATURE_STRICT_MODE,
Context.FEATURE_STRICT_VARS,
Context.FEATURE_STRICT_EVAL,
Expand All @@ -40,7 +40,7 @@ public void onlyGetterError() {
final String script = "o.readonlyProp = 123";

Utils.runWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_STRICT_MODE),
Utils.contextFactoryWithFeatures(Context.FEATURE_STRICT_MODE),
cx -> {
try {
Scriptable scope = cx.initSafeStandardObjects();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ public void redefineSetterProperty() throws Exception {
public void redefinePropertyWithThreadSafeSlotMap() {

final ContextFactory factory =
new Utils.FeatureContextFactory(Context.FEATURE_THREAD_SAFE_OBJECTS);
Utils.contextFactoryWithFeatures(Context.FEATURE_THREAD_SAFE_OBJECTS);

try (Context cx = factory.enterContext()) {
cx.setLanguageVersion(Context.VERSION_ES6);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public void toLocaleLowerCase() {
String js = "'\\u0130'.toLocaleLowerCase()";

Utils.runWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
cx -> {
final Scriptable scope = cx.initStandardObjects();
cx.setLanguageVersion(Context.VERSION_ES6);
Expand All @@ -35,7 +35,7 @@ public void toLocaleLowerCase() {
});

Utils.runWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
cx -> {
final Scriptable scope = cx.initStandardObjects();
cx.setLanguageVersion(Context.VERSION_ES6);
Expand All @@ -50,20 +50,20 @@ public void toLocaleLowerCase() {
@Test
public void toLocaleLowerCaseParam() {
Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0069\u0307",
"'\\u0130'.toLocaleLowerCase('en')");
Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0069",
"'\\u0130'.toLocaleLowerCase('tr')");

Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0069\u0307",
Expand All @@ -75,7 +75,7 @@ public void toLocaleUpperCase() {
String js = "'\\u0069'.toLocaleUpperCase()";

Utils.runWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
cx -> {
final Scriptable scope = cx.initStandardObjects();
cx.setLanguageVersion(Context.VERSION_ES6);
Expand All @@ -87,7 +87,7 @@ public void toLocaleUpperCase() {
});

Utils.runWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
cx -> {
final Scriptable scope = cx.initStandardObjects();
cx.setLanguageVersion(Context.VERSION_ES6);
Expand All @@ -102,20 +102,20 @@ public void toLocaleUpperCase() {
@Test
public void toLocaleUpperCaseParam() {
Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0049",
"'\\u0069'.toLocaleUpperCase('en')");
Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0130",
"'\\u0069'.toLocaleUpperCase('tr')");

Utils.assertWithAllModes(
new Utils.FeatureContextFactory(Context.FEATURE_INTL_402),
Utils.contextFactoryWithFeatures(Context.FEATURE_INTL_402),
Context.VERSION_ES6,
null,
"\u0049",
Expand Down

0 comments on commit 25b30bf

Please sign in to comment.