Skip to content

Commit

Permalink
Merge pull request #24 from chibash/transpiler
Browse files Browse the repository at this point in the history
changes test code so that all the test cases can concurrently run.
  • Loading branch information
maejima-fumika authored Nov 19, 2024
2 parents 434daff + b49aed5 commit b5b57ee
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion server/tests/jit/test-jit-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export function tempCFilePath(fname: string) {
}

export function tempExecutableFilePath(fname: string) {
return `./temp-files/${fname}`;
return `./temp-files/${fname}-jit`;
}

export function initialCompile(destFile: string) {
Expand Down
8 changes: 4 additions & 4 deletions server/tests/transpiler/code-generator/code-generator.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1916,11 +1916,11 @@ test('property accesses', () => {
3, 23, 23, 25, 25, 23].join('\n') + '\n')
})

test.only('multiple source files for classes', () => {
test('multiple source files for classes', () => {
const src1 = `
class Pos {
x: number
constructor(x: number) { this.x = 3 }
constructor(x: number) { this.x = x + 3 }
}
`

Expand All @@ -1929,11 +1929,11 @@ test.only('multiple source files for classes', () => {
constructor(x: number, y: number) { super(x); this.y = y }
}
const obj = new Pos3(3, 11)
const obj = new Pos3(7, 11)
print(obj.x)
`

expect(multiCompileAndRun(src1, src2)).toEqual('3\n')
expect(multiCompileAndRun(src1, src2)).toEqual('10\n')
})

test('access a class in another source file', () => {
Expand Down

0 comments on commit b5b57ee

Please sign in to comment.