Skip to content
This repository was archived by the owner on May 28, 2019. It is now read-only.

Sauce Labs Automated Testing #49

Closed
wants to merge 1 commit into from
Closed

Sauce Labs Automated Testing #49

wants to merge 1 commit into from

Conversation

bnjmnt4n
Copy link
Member

Travis CI has already been integrated into JSON3, so I think we can start to implement automated browser testing with Sauce Labs. Lo-Dash has been doing this for some time already, with great results. The only problem with implementing this is that Spec, the test suite we use, is not natively supported, meaning we have to use wd (Selenium/WebDriver library) to access the test results ourselves.

@ghost ghost added the enhancement label Feb 23, 2014
@bnjmnt4n
Copy link
Member Author

I'll work on this on the saucelabs branch with my saucelabs info for now

@jdalton
Copy link
Member

jdalton commented May 16, 2014

Why hide the sauce username? I assume you'll have badges or link to the results page, which exposes the sauce username anyways, it's a public project after all.

@bnjmnt4n
Copy link
Member Author

Yeah, I was using my username first. Eventually I'll change that.

@jdalton
Copy link
Member

jdalton commented May 16, 2014

Cool.

@ghost ghost closed this Jun 22, 2014
@ghost ghost reopened this Jun 22, 2014
@bnjmnt4n bnjmnt4n force-pushed the dev branch 2 times, most recently from 941af21 to 9eca041 Compare October 21, 2014 02:51
@bnjmnt4n bnjmnt4n force-pushed the dev branch 3 times, most recently from e8e8ecb to 34fe379 Compare November 15, 2014 05:52
@ghost
Copy link

ghost commented Dec 24, 2014

Let's think about migrating away from Spec if it makes Sauce integration easier.

@jdalton
Copy link
Member

jdalton commented Dec 24, 2014

Sauce supports custom unit test libs :D 🐐

@bnjmnt4n
Copy link
Member Author

Yeah, it does, was a bit busy. There’s no need to switch from Spec. Will try to finish soon.

@ghost
Copy link

ghost commented Dec 25, 2014

Cool. No rush at all; just curious if switching to something like QUnit would make things easier. Thanks, @jdalton and @D10! 😺

@bnjmnt4n bnjmnt4n force-pushed the saucelabs branch 2 times, most recently from 05748cf to c6ca0d5 Compare January 1, 2015 10:06
@ghost ghost mentioned this pull request Mar 8, 2015
6 tasks
@bnjmnt4n
Copy link
Member Author

bnjmnt4n commented Mar 9, 2015

I made a support request on Sauce Labs, since the tests worked fine, yet they were failing on Sauce Labs. One of the awesome people at Sauce Labs, @saucyallison, responded:

I took a look at your test, and then did some testing of my own. I don't see anything wrong with your test, but I think I've found the reason your test results aren't displaying properly.
I took the contents of your window.global_test_results and put them on a sandbox html page so I could use it with the JS unit test API. My tests were returning "Finished" instead of the proper results like your tests were. I noticed that the window.global_test_results was a fairly large object, so I tried removing test info from it. Eventually, with enough info removed, the unit test results display as expected, with Pass/Fail status.
I think the underlying problem here is that the window.global_test_results are stored in the "custom data" field in our database (and on the Metadata tab in the test details page), which has a maximum size. Once this limit is reached, the custom data field gets set to null instead. The size limit is supposed to be 64 KB, but it looks like the size of your input is closer to 42KB, so I believe there's something wrong with our logic. We're looking into increasing the size of this field in the near future! In the meantime, my advice would be to cut your tests down into smaller chunks.
Here is an example of the largest global_test_results object I was able to get working: https://saucelabs.com/tests/ffef55684c3748c683db30e8d9bf3e56
For this one, I added one additional unit test, and the results stopped displaying correctly: https://saucelabs.com/tests/b9c9c9461db7409b8bb789dfa4bc45ab
Hope this helps! Sorry for the confusion here, I know this kind of problem isn't very self-explanatory. Let me know if you have further questions, thank you!

For now, I'll just not add passing tests to the global_test_results variable, until @saucelabs fixes this.

@bnjmnt4n bnjmnt4n force-pushed the saucelabs branch 5 times, most recently from 954e116 to 6647180 Compare March 13, 2015 11:40
@bnjmnt4n
Copy link
Member Author

@kitcambridge This now works. Feel free to rebase/merge this. (Test fails are not related, they are due to the Rhino download.)

@ghost
Copy link

ghost commented Mar 17, 2015

This is awesome. 🌟 Thanks so much, @D10! I'll merge tonight.

@ghost
Copy link

ghost commented Apr 9, 2015

"Three weeks" is an interesting definition of "tonight." 😿 Sorry for letting this slide; I've been really busy. Merging now.

ghost pushed a commit that referenced this pull request Apr 9, 2015
@jdalton
Copy link
Member

jdalton commented Apr 9, 2015

Booo GoLang Boo! : D

@ghost
Copy link

ghost commented Apr 9, 2015

@jdalton Go was four weeks ago...it's Twisted Python now. 😜

@ghost
Copy link

ghost commented Apr 9, 2015

Merged as 2043202. Thanks again for the great work, @D10. Let's see if #78 fixes the Date-related failures...

@ghost ghost closed this Apr 9, 2015
@bnjmnt4n bnjmnt4n deleted the saucelabs branch April 10, 2015 03:48
@bnjmnt4n
Copy link
Member Author

Great banter, m8! ;)

This pull request was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

Successfully merging this pull request may close these issues.

2 participants