-
Notifications
You must be signed in to change notification settings - Fork 51
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
Easier way to specify path of custom parser #85
Comments
Ah yep this looks like a bug. Thanks for reporting! I'm not on windows but I can replicate on OSX with a relative path. I'll try to get a fix out tomorrow but it may take until next week. Feel free to submit a PR if you have a fix of your own! |
I have a potential fix for this in 874a08e would you mind trying that out? I don't have a windows machine so there could be something that doesn't work there. Thanks! |
Gladly! I'll try to get to it this weekend. If not, then on Monday for sure. I'll report back as soon as I've tried it. Thanks! |
All right - I tested and can confirm that all of the following work:
I think it looks good - thanks! |
This has been published to NPM as |
Hello,
I just started using
protractor-flake
today and I'm really liking it so far - thanks!There's one thing I've run into that I had to work around - the custom parser path seems to use
require.resolve
which seems to use__dirname
or equivalent to look for the file. However, I've installedprotractor
andprotractor-flake
globally, so I'm running my tests from a different directory than whereprotractor-flake
is installed.I did some quick tests tweaking the source and in
parsers/index.js handlePath
function if I do something like:Then it works for me. Maybe you could nest that (or some nicer equivalent) in the catch block to support relative paths from the calling directory?
Alternatively, maybe there's a better way for me to achieve this? For now I'm specifying my custom parser path on the command line with
%CD%\subdirectory\parser.js
which works due to expansion before being passed in...Thanks for considering and keep up the good work.
The text was updated successfully, but these errors were encountered: