"Missing sauce script" Error when trying to test with Sauce Labs



I’m having an issue by following the documentation under http://circleci.com/docs/2.0/browser-testing/#sauce-labs.
When I put the config.yml file just as indicated there, this is:

 version: 2
       - image: circleci/python:jessie-node-browsers
       - checkout
       - run: 
           name: Install Sauce
           command: npm install saucelabs
       - run: 
           name: sauce testing
           command: npm run-script sauce
       - run: # Wait for app to be ready
           command: wget --retry-connrefused --no-check-certificate -T 30 <localhost : 5000>
       - run: # Run selenium tests
           command: nosetests
       - run: # wait for Sauce Connect to close the tunnel
           command: killall --wait sc

Note: I replaced the actual localhost port 5000 URL on the code snippet, because I got an error about new user’s post. But, where it says “<localhost : 5000>” it’s supposed to have an URL of localhost port 5000.

I’m getting the following error during Circle CI build:

I don’t know if I am supposed to generate that “sauce” script or it should be already installed after installing saucelabs, or even present on the circle ci image built for execution.

I tried running a test-sauce script by my own, I can post it if you respond that I need my own sauce script.



I unfortunately think those docs are inaccurate. saucelabs is an npm module for interacting with Sauce’s rest API (account info, job history, etc), not the testing connect tunnel - https://www.npmjs.com/package/saucelabs

And npm run-script sauce would expect sauce to be a provided script.

What language is your project in? Are you testing against an app running in the circleCI container (not deployed to public URL?)
Their might be some libraries to get you rolling, or we can walk through steps to download and install the sauce Connect Tunnel and then we can submit any corrections to the docs.



I updated my Java project to use Sauce Connect tunnel. All my tests are selenium driven by Java, so you’ll need to consider what’s appropriate for your application.


This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.