Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tern tests on windows #164

Closed
albertosantini opened this issue May 28, 2013 · 2 comments
Closed

Tern tests on windows #164

albertosantini opened this issue May 28, 2013 · 2 comments

Comments

@albertosantini
Copy link

On windows box I have been investigating about ternjs/tern_for_vim#18 and I saw there is a test case about relative files in node environment.

So I execute npm test from git bash shell and I get

> tern@0.1.1 test c:\My\Dev\snippets\tern
> ./bin/test

'.' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! weird error 1
npm ERR! not ok code 0

Plan B: node ./bin/test

And all the tests fail due to the following line in runcases.js:

var typedef = /\/\/(<)?(\+|::?|:\?|doc:|loc:|refs:) *([^\n]*)/g, m;

I added the end of line for windows (just to try):

var typedef = /\/\/(<)?(\+|::?|:\?|doc:|loc:|refs:) *([^\r\n]*)/g, m;

And now only 44 tests fail. :)

I need to investigate further.

@marijnh
Copy link
Member

marijnh commented May 31, 2013

That suggests node is adding \r's before newlines when reading files that, themselves, only have newlines. That's odd! Your patch is harmless, and I've applied it, but I'd still like to get to the bottom of what node is doing there.

The remaining failing tests are, of course, also cause for concern (and might be related to ternjs/tern_for_vim#18). I'll try to set up a windows node next week and debug this further.

@marijnh
Copy link
Member

marijnh commented Jun 3, 2013

Should be better as of 26a12e8 (at least for me, on Win7, the test all pass now)

@marijnh marijnh closed this as completed Jun 3, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants