/demo-csharp

A repository containing all C# examples for Sauce

Primary LanguageC#MIT LicenseMIT

C# Sauce Labs Demo Scripts and Frameworks

Codacy Badge

This directory contains example scripts and dependencies for running automated Selenium tests on Sauce Labs using C#.

🖥 Web automation

🥇Best practice frameworks for web testing

Code Examples

All examples are using .NET and Mstest unless specified

📕Training

📱Mobile automation

🥇Best practice frameworks for mobile testing

Examples

🚀 CICD

Azure DevOps

Azure DevOps Sauce Labs Plugin does NOT work! You cannot view Sauce Labs videos inside of Azure DevOps. You need to go to saucelabs.com to view the test assets. You can add richer logging to your tests and add test asset links directly into the logs (but this is extra work).

Build Status

How to configure Azure DevOps with Sauce Labs

Example task to run tests in Sauce

- task: DotNetCoreCLI@2
  displayName: 'Run tests'
  inputs:
    command: test
    projects: '**DotnetCore/Sauce.Demo/*.csproj'
    arguments: '--configuration $(buildConfiguration) --filter TestCategory=desktop'
  env:
    SAUCE_USERNAME: $(sauceUsername)
    SAUCE_ACCESS_KEY: $(sauceKey)

Github Actions

Coming soon...

Parallelization capabilities of unit testing libraries

How do different libraries parallelize tests?

MsTest NUnit xUnit SpecFlow
Test method Test class Test class Test class