bensu / doo

doo is a library and lein plugin to run cljs.test on different js environments.
Eclipse Public License 1.0
324 stars 63 forks source link

end to end testing example phantom opts #140

Open ransomw opened 6 years ago

ransomw commented 6 years ago

i found it necessary to modify the End to end testing example from the wiki in order for phantom to make cors requests:

both --web-security=false and --local-to-remote-url-access=true are necessary to prevent a

XMLHttpRequest cannot load http://localhost:3333/demo/hello. Cross origin requests are not supported.

out of phantom.

it's possible to try it out with (do (reload-require) (run-doo-tests)) in a lein repl with the source linked above, toggling phantom opts between (do (reload-require) (run-doo-tests))ing in the repl.


i suppose an update might not be such a priority since other issues indicate that phantom is on the way out .. anyway, i wanted to get it documented here as an issue, even if the next update to the wiki includes chromium headless rather than phantom.

MatthewDarling commented 6 years ago

Chrome Headless support is available starting with lein-doo version 0.1.8 :)

Should the linked tutorial (and others?) be updated to use it, rather than PhantomJS? Any volunteers to do so?

I seem to have permission to edit the wiki. Happy to do the edits if someone else writes the text.