motanelu / bcn-js-news-widget

Demo app for my presentation - Crossbrowser testing with Nightwatch, Travis and Saucelabs

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build Status

Build Status js-standard-style

bcnjs

Demo application for BarcelonaJS

This repository is part of a proof of concept on how to use Nightwatch together with Saucelabs and express to test frontend applications both locally and on Travis in isolation. It creates a Vuejs widget that can be dropped in any page, connects to a configurable API and displays news.

new NewsWidget({
  'selector': '#widget',
  'api': 'some.url',
  'userId': 1
})

The slides from the presentation are available on SlideShare

Resources:

Prerequisites

First install all the dependencies by running

npm install

Create a Saucelabs account, install sauce-connect available via brew for OSX users and export the credentials as environment variables.

brew cask install sauce-connect
export SAUCE_USERNAME="..."
export SAUCE_ACCESS_KEY="..."

Start the tunnel to Saucelabs by calling sauce-connect. Sauce-connect needs to be running for the entire duration of the tests, stopping it will sever the link to Saucelabs.

sc

In a new terminal, run

npm run test

About

Demo app for my presentation - Crossbrowser testing with Nightwatch, Travis and Saucelabs

License:GNU Lesser General Public License v3.0


Languages

Language:JavaScript 72.2%Language:Vue 25.5%Language:HTML 2.3%