Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

The tests fail on Windows preventing pushing #272

Open
aminya opened this issue Apr 8, 2021 · 2 comments
Open

The tests fail on Windows preventing pushing #272

aminya opened this issue Apr 8, 2021 · 2 comments

Comments

@aminya
Copy link
Contributor

aminya commented Apr 8, 2021

So far in all my contributions, I had to remove the pre-push hook.

 FAIL  test/cli.test.ts
   cli  should error any files with errors

    expect(jest.fn()).toHaveBeenCalledWith(...expected)

    Expected: "error processing C:\\Users\\aminy\\AppData\\Local\\Temp\\tmp-8188mp3sINyCgeD1\\test.js"
    Received
           1: "error processing C:/Users/aminy/AppData/Local/Temp/tmp-8188mp3sINyCgeD1/test.js"
           2: [SyntaxError: Unexpected token (1:0)]

    Number of calls: 2

      93 |     fs.writeFileSync(inputPath, "const a: number = 5;", "utf-8");
      94 |
    > 95 |     // Act
         |                     ^
      96 |     cli([
      97 |       "node",
      98 |       path.join(__dirname, "../flow-to-ts.js"),

      at Object.<anonymous> (test/cli.test.ts:95:27)
@kevinbarabash
Copy link
Contributor

@aminya it looks like it's failing to run the jest tests. Do the tests pass when you run them manually?

@kevinbarabash
Copy link
Contributor

I see, the error message is different. I think the expect can be changed so that it isn't looking for a path that's specific to a certain OS.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants