Add a command to use master version of elm-explorations/test#592
Add a command to use master version of elm-explorations/test#592lydell merged 23 commits intortfeldman:masterfrom Janiczek:master
Conversation
|
From Discord:
|
|
I wonder if this could even take an argument, so that it could be used to test locally other branches? |
|
@gampleman My initial assumption when hearing @harrysarson's idea was that this would later be reverted, and not a long-term flag. If it was to be longterm, I agree customizing it could be a nice addition. |
|
I've incorporated your feedback @lydell although I'm sure my implementation will need some more improvements. It works on my Mac machine but I haven't tried the |
There was a problem hiding this comment.
TODO:
- Make CI pass
- Test manually on Windows (I think
spawn.syncthrows an error rather than returning a non-zero exit code ifunzipdoes not exist). EDIT: No, the approach with the exit codes works, at least on macOS. So it’s just about verifying that it works on Windows.
harrysarson
left a comment
There was a problem hiding this comment.
I am happy to delegate detail review to others, the shape of this PR looks great!
Given this is a tool to test the new elm-explorations which should be uniform across platforms (its elm) I would think we need windows support (although it would obviously be cool to have).
I was thinking of this being something we revert, but if we end up liking I could see us building it out |
|
@Janiczek Let me know if you need help getting |
|
Hey @lydell, thanks for the review and your offer! I was a bit swamped with other work, didn't even notice your last few comments 😅 I hope to take a look at this tomorrow and get the PR into shape. |
|
This now works via a pair of commands:
|
|
@Janiczek I fixed the CI failure, but since you used your Edit: I made a pull request to your pull request: https://github.com/Janiczek/node-test-runner/pull/1 |
|
This is looking really good now! I finally tested on Windows, and unfortunately I ran into an error: Not sure why that happens yet. |
|
I figured it out! Made another PR here: https://github.com/Janiczek/node-test-runner/pull/2/files |
Make it work on Windows
lib/Install.js
Outdated
| }); | ||
|
|
||
| // The destination stream is ended by the time it's called | ||
| file.on('finish', () => resolve(fileInfo)); |
There was a problem hiding this comment.
We seem to resolve the promise with some data we never use here.
lib/Install.js
Outdated
| return 'SuccessfullyInstalled'; | ||
| } | ||
|
|
||
| async function downloadFileNative(url, filePath) { |
There was a problem hiding this comment.
Maybe we should add type annotations to all new functions in this file – for parameters and return types.
There was a problem hiding this comment.
Went ahead and did the last final touches: https://github.com/Janiczek/node-test-runner/pull/3
|
One final final question 😅 What way is the easiest to verify that:
|
|
Replying to myself, I figured out an easy way to test: I added However, I first thought it didn’t work, because I tried with Here’s where 1.2.2 is mentioned multiple times:EDIT: Added a check in https://github.com/Janiczek/node-test-runner/pull/3. It was easy enough. |
|
Good to see you figured how to test this out:
But anyways just to post my way of testing this, I've simply ran this local version of elm-test in one of my repos that had
So it's usually fine to do something like cd ~/Localhost/elm/elm-secret-sharing
../../cloned/node-test-runner/bin/elm-test # 1.2.2, works
../../cloned/node-test-runner/bin/elm-test install-unstable-test-master
../../cloned/node-test-runner/bin/elm-test # master, doesn't work
../../cloned/node-test-runner/bin/elm-test uninstall-unstable-test-master
../../cloned/node-test-runner/bin/elm-test # 1.2.2, works |
Final touches
|
I noticed that the intellij-elm plugin does not like when I run |
I don't use that one (I'm pretty light on Elm editor plugins) so I didn't notice 😬 |
|
Found the issue and made a PR: https://github.com/Janiczek/node-test-runner/pull/4 |
Install package elm-explorations/test after uninstalling master
|
Those auto-close comments are treacherous 😁 |
This is based on a discussion in the Incremental Elm #elm-test Discord channel.
The intent is to allow people to help us beta-test the
elm-explorations/test2.0.0 release and use themasterversion ofelm-explorations/teston their codebases (masqueraded as the 1.2.2 version).cc @harrysarson
vid.mp4