New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@wdio/sauce-service

Package Overview
Dependencies
Maintainers
0
Versions
512
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wdio/sauce-service

WebdriverIO service that provides a better integration into Sauce Labs

  • 9.7.3
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
65K
decreased by-30.6%
Maintainers
0
Weekly downloads
 
Created

What is @wdio/sauce-service?

@wdio/sauce-service is a WebdriverIO service that provides integration with Sauce Labs, a cloud-based platform for testing web and mobile applications. It allows you to run your WebdriverIO tests on Sauce Labs' infrastructure, which includes a wide range of browsers and devices.

What are @wdio/sauce-service's main functionalities?

Sauce Labs Integration

This feature allows you to configure and run your WebdriverIO tests on Sauce Labs. The code sample demonstrates how to set up a test with Sauce Labs using WebdriverIO, specifying the browser, platform, and Sauce Labs options.

const { remote } = require('webdriverio');

const options = {
  user: 'your-username',
  key: 'your-access-key',
  services: ['sauce'],
  capabilities: {
    browserName: 'chrome',
    platformName: 'Windows 10',
    browserVersion: 'latest',
    'sauce:options': {
      name: 'My Test',
      build: 'Build-1234'
    }
  }
};

async function main() {
  const browser = await remote(options);
  await browser.url('https://www.example.com');
  console.log(await browser.getTitle());
  await browser.deleteSession();
}

main();

Automatic Test Reporting

This feature provides automatic reporting of test results to Sauce Labs. The code sample shows how to handle test execution and ensure that results are reported back to Sauce Labs, even if the test fails.

const { remote } = require('webdriverio');

const options = {
  user: 'your-username',
  key: 'your-access-key',
  services: ['sauce'],
  capabilities: {
    browserName: 'chrome',
    platformName: 'Windows 10',
    browserVersion: 'latest',
    'sauce:options': {
      name: 'My Test',
      build: 'Build-1234'
    }
  }
};

async function main() {
  const browser = await remote(options);
  try {
    await browser.url('https://www.example.com');
    console.log(await browser.getTitle());
  } catch (error) {
    console.error('Test failed', error);
  } finally {
    await browser.deleteSession();
  }
}

main();

Other packages similar to @wdio/sauce-service

Keywords

FAQs

Package last updated on 05 Feb 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc