Skip to content

Commit 906df50

Browse files
committed
Fixed broken tests
1 parent 31b41b7 commit 906df50

File tree

2 files changed

+3
-11
lines changed

2 files changed

+3
-11
lines changed

test/translation/lua/namespaceMerge.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
MergedClass = MergedClass or {};
22
MergedClass.__index = MergedClass;
33
MergedClass.new = function(construct, ...)
4-
local self =setmetatable({}, MergedClass);
4+
local self = setmetatable({}, MergedClass);
55
self.propertyFunc = function(____)
66
end;
77
if construct and MergedClass.constructor then

test/unit/expressions.spec.ts

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ export class ExpressionTests {
1313
@TestCase("--i", "i = i - 1;")
1414
@TestCase("!a", "not a;")
1515
@TestCase("-a", "-a;")
16-
@TestCase("let a = delete tbl['test']", "local a = (function ()\n tbl.test = nil;\n return true;\nend)();")
16+
@TestCase("let a = delete tbl['test']", "local a = (function()\n tbl.test = nil;\n return true;\nend)();")
1717
@TestCase("delete tbl['test']", "tbl.test = nil;")
18-
@TestCase("let a = delete tbl.test", "local a = (function ()\n tbl.test = nil;\n return true;\nend)();")
18+
@TestCase("let a = delete tbl.test", "local a = (function()\n tbl.test = nil;\n return true;\nend)();")
1919
@TestCase("delete tbl.test", "tbl.test = nil;")
2020
@Test("Unary expressions basic")
2121
public unaryBasic(input: string, lua: string): void {
@@ -204,14 +204,6 @@ export class ExpressionTests {
204204
@TestCase("true ? undefined : true", undefined, { luaTarget: LuaTarget.LuaJIT })
205205
@Test("Ternary operator")
206206
public ternaryOperator(input: string, expected: any, options?: ts.CompilerOptions): void {
207-
console.log(util.transpileString(
208-
`const literalValue = 'literal';
209-
let variableValue:string;
210-
let maybeBooleanValue:string|boolean = false;
211-
let maybeUndefinedValue:string|undefined;
212-
return ${input};`, options
213-
214-
));
215207
const result = util.transpileAndExecute(
216208
`const literalValue = 'literal';
217209
let variableValue:string;

0 commit comments

Comments
 (0)