Closed rkatic closed 10 years ago
It's seems the problem is https://github.com/substack/node-browserify/issues/775. Would like if we make testing in local browsers easier. It's essential for testing during developing.
The origin probably should be "*"
. As for Browserify, we’re using on of my other projects Mr, so you can use <script src="../node_modules/mr/boot.js" data-package=".." data-module="test/asap-test"></script>
to load during development, or ./node_modules/.bin/mrs test/asap-test.js
to generate a bundle.
Though it occurs to me that we’re not directly invoking postMessage ever, which is curious. I’m seeing this issue myself after merging #45 locally even when using Mr, and seeing errors across many browsers on Sauce.
Note that this build matrix will probably be out of date if I run the tests on sauce again, which I’ll wait for your acknowledgement before doing.
Oh, right. I call it in scaffold to report worker test results. I’ll patch that and rerun.
@rkatic I’ve documented the testing procedures https://github.com/kriskowal/asap/blob/master/CONTRIBUTING.md
Note also the existence of test/index.html which will run without a build step in a browser.
:+1:
Since I don't have the
credentials.json
file, I was unable to publish to S3 for testing. So I tried to test in my browser. I browserify-edasap-test.js
, linked it in a HTML file, and opened the page. There are 6 failing tests. Also, at the end I have this error:Uncaught SyntaxError: Failed to execute 'postMessage' on 'Window': Invalid target origin '' in a call to 'postMessage'.
("scafold.js" at line 39)Didn't have more time to investigate. Am I doing something wrong?