Skip to content

Commit

Permalink
test: Fix more fixtures
Browse files Browse the repository at this point in the history
  • Loading branch information
flovogt committed Mar 28, 2024
1 parent fd2aa82 commit 74c5dbc
Show file tree
Hide file tree
Showing 5 changed files with 43 additions and 53 deletions.
20 changes: 9 additions & 11 deletions test/fixtures/transpiler/amd/Require_Callback_2.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,21 +49,21 @@ window.sap.ui.require(["my/module"], (Module) => {
window[sap.ui.require(["my/module"], (Module) => {
return Module;
})];
window.["window"]sap.ui.require(["my/module"], (Module) => {
window["sap"].ui.require(["my/module"], (Module) => {
return Module;
});

window.["sap"]["ui"]["require"](["my/module"], (Module) => {
window["sap"]["ui"]["require"](["my/module"], (Module) => {
return Module;
});

let val = sap.ui.require(["my/module"], (Module) => {
let val6 = sap.ui.require(["my/module"], (Module) => {
return Module;
});
let val2 = sap.ui.require(["my/module"], (Module) => {
let val7 = sap.ui.require(["my/module"], (Module) => {
return Module;
}) + 1;
let val3 = () => sap.ui.require(["my/module"], (Module) => {
let val8 = () => sap.ui.require(["my/module"], (Module) => {
return Module;
});

Expand All @@ -87,7 +87,7 @@ for (let i = 0; i < sap.ui.require(["my/module"], (Module) => {
})[i]
}

function () {
function fn1() {
sap.ui.require(["my/module"], (Module) => {
return Module;
});
Expand All @@ -103,7 +103,7 @@ function () {
return Module;
}));

var function () {
function fn2() {
sap.ui.require(["my/module"], (Module) => {
return Module;
});
Expand All @@ -124,7 +124,7 @@ class MyClass {
});
[sap.ui.require(["my/module"], (Module) => {
return Module;
})]: "foo";
})];
load() {
sap.ui.require(["my/module"], (Module) => {
return Module;
Expand All @@ -138,9 +138,7 @@ function* generatorFunction() {
});
}

var deps = ["my/module"], (Module) => {
return Module;
};
var deps = ["my/module"];
var callback = (MyModule) => {
console.log(MyModule);
};
Expand Down
14 changes: 7 additions & 7 deletions test/fixtures/transpiler/amd/Require_Import_2.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ const arr = [sap.ui.require(["my/module"]), sap.ui.require(["my/module"])];
let val = sap.ui.require(["my/module"]);
let val2 = sap.ui.require(["my/module"]) + 1;
let val3 = -sap.ui.require(["my/module"]);
let val5 = () => sap.ui.require(["my/module"]);
let val4 = () => sap.ui.require(["my/module"]);

window.sap.ui.require(["my/module"]);
window[sap.ui.require(["my/module"])];
window.["sap"].ui.require(["my/module"]);
window["sap"].ui.require(["my/module"]);

let val = sap.ui.require(["my/module"]);
let val2 = sap.ui.require(["my/module"]) + 1;
let val3 = () => sap.ui.require(["my/module"]);
let val5 = sap.ui.require(["my/module"]);
let val6 = sap.ui.require(["my/module"]) + 1;
let val7 = () => sap.ui.require(["my/module"]);

new val(sap.ui.require(["my/module"]))(sap.ui.require(["my/module"]));

Expand All @@ -42,7 +42,7 @@ for (let i = 0; i < sap.ui.require(["my/module"]); i++) {
sap.ui.require(["my/module"])[i]
}

function () {
function fn1() {
sap.ui.require(["my/module"]);
}

Expand All @@ -52,7 +52,7 @@ function () {

(() => sap.ui.require(["my/module"]));

var function () {
function fn2() {
sap.ui.require(["my/module"]);
}

Expand Down
14 changes: 7 additions & 7 deletions test/fixtures/transpiler/amd/Require_Probing_2.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ const arr = [sap.ui.require("my/module"), sap.ui.require("my/module")];
let val = sap.ui.require("my/module");
let val2 = sap.ui.require("my/module") + 1;
let val3 = -sap.ui.require("my/module");
let val5 = () => sap.ui.require("my/module");
let val4 = () => sap.ui.require("my/module");

window.sap.ui.require("my/module");
window[sap.ui.require("my/module")];
window.["sap"].ui.require("my/module");
window["sap"].ui.require("my/module");

let val = sap.ui.require("my/module");
let val2 = sap.ui.require("my/module") + 1;
let val3 = () => sap.ui.require("my/module");
let val5 = sap.ui.require("my/module");
let val6 = sap.ui.require("my/module") + 1;
let val7 = () => sap.ui.require("my/module");

new val(sap.ui.require("my/module"))(sap.ui.require("my/module"));

Expand All @@ -43,7 +43,7 @@ for (let i = 0; i < sap.ui.require("my/module"); i++) {
sap.ui.require("my/module")[i]
}

function () {
function fn1() {
sap.ui.require("my/module");
}

Expand All @@ -53,7 +53,7 @@ function () {

(() => sap.ui.require("my/module"));

var function () {
function fn1() {
sap.ui.require("my/module");
}

Expand Down
Loading

0 comments on commit 74c5dbc

Please sign in to comment.