-
Notifications
You must be signed in to change notification settings - Fork 81
Spectron/Webdriver integration test example #62
base: master
Are you sure you want to change the base?
Conversation
@asticode - Quentin - this PR hasnt gotten any comments - should I take it that you are not interested in integrating the test example into the demo? If not, that's OK - I'll create a new repo and put the example there. |
@chinenual to be honest I came back to this PR a couple times but it always felt like it belonged to another repo. Creating a new repo seems like the best idea, we could add a link to it in the README though |
@asticode Sounds good. I'll let you know when its ready with a PR for the README? I plan to call it chinenual/go-astilectron-uitest unless you have a preference for something else? |
Feel free to name the repo as you wish, but I think it's a good choice 👍 |
@asticode - I'm having some trouble deciding how best to structure this. The ui-test requires a small change to the main.go (to set the executer and allow the test driver to set the tcpport) and in a real project it would be part of the project; not a separate repo. I really don't want to copy/paste all of the demo into the test example project, but am not sure the best way to explain
Ideas on best way to structure this? |
I think your repo should be a ready-to-be-run project with a nice README. Maybe don't copy/paste the demo project, but you'll need to set up a minimalist project using the
The only solution I can think of is a nice README
Either explain what needs to be copied in the README, or encourage developers to git clone your repo to test the process using your test project. Then, once the repo has been already git cloned, they can safely copy the content of the directories. |
Agreed. I'll let you know when I have something ready. |
I've tested this successfully on both Mac and Windows. I'm getting a mystery error on Linux, and I'll continue to investigate since I need this to work on Linux for my project.
But I'm pushing this now so you can review and let me know if you would like it restructured or changed.
One known limitation: the test won't work unless the electron artifacts have been provisioned (the readme warns that you need to run the application once manually before trying to test). I think I coud fix that by calling the default provisioner from my Adapter -- but the default provisioner isn't exported from astilectron package and its probably not clean to copy/paste it into the demo. I could do a PR to expose the default provisioner (as you do with the DefaultExecuter), if you agree?