-
Notifications
You must be signed in to change notification settings - Fork 22
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
10 tests fail on Windows #9
Comments
For 168 and 169, I can sort of imagine incorrect handling of path separator. I guess the rest of the failed tests may also be affect by that. |
If you can give me some tips to debug and test just one test at a time, I think I might be able to figure it out. Also, it's a bit hard for me to navigate these tests and find the appropriate one. I'm not at all familiar w/ ctest. |
Is this where the two Windows tests are written? |
Or is this where I should be looking? |
These tests are pretty hard to read. I can't tell what the input/output is or what the expected value should be. Definitely not what I'm used to. |
You should run |
Yeah. I knew that. I'm just expecting to see something like: expect(foo('bar')).toEqual('baz'); Where it's very clear that I don't know how to translate what I'm seeing into that mindset. |
For example:
How do I read that? |
|
If I navigate to the
The output is:
Which I presume came from /^[ \t\n\r]*$/.test('key=value'); // false Am I missing something? Or was it not supposed to hit line 12? Is there an assumption here that EditorConfig wouldn't actually work on Windows, but it is, which is throwing the test off? |
@jedmao I can vaguely remember that we decided that all path separators in brackets must be |
I see, so it seems there actually is something wrong with the js core in that it shouldn't be accepting back slashes. That would make some sense. The regex above is saying there should be no match, just white spaces, right? |
Yes, that's correct. |
@xuhdev, I think it would make sense to document our ini-like format in something that sounds more like English than these tests so we don't have similar confusions now or in the future. |
I know for a fact that minimatch, the library that the js core has modified internally, accepts any variety of slashes, so that would do it. |
OK, I fixed it in the doc: editorconfig/editorconfig.github.com@44b8cc1 |
Is this issue still relevant today? |
Yes. I think it warrants adding AppVeyor to the CI builds. |
Example Appveyor config, in case it helps: https://github.com/cxw42/editorconfig-core-vimscript/blob/master/appveyor.yml |
Sure thing. I’ll try to find some time. |
@cxw42 I put up a PR, but it breaks the build. I don't think the issue is with the new tests, however. I think there's actually a problem with the js core, which I was trying to fix a while back in this PR. Really, it's the INI parser that's the problem, from what I can tell. Perhaps we need something with more of a formal grammar. |
Thanks for giving it a shot! If I get any ideas about the build failure, I'll let you know. |
This is a long-standing issue (years) that continues to plague me when working on the
editorconfig-core-js
project. These tests run fine in the Travis-CI environment, but fail on Windows in my local dev environment.@xuhdev do you know if there's something special about these particular tests that would make them fail on Windows, specifically? It makes it pretty difficult to do development when I have to wait for the CI environment to finish each run.
The text was updated successfully, but these errors were encountered: