diff --git a/.gitignore b/.gitignore index ac3bb30fc..6926d5f78 100644 --- a/.gitignore +++ b/.gitignore @@ -32,6 +32,7 @@ Thumbs.db /node_modules /bower_components npm-debug.log* +yarn.lock # Coverage # /coverage/ @@ -66,6 +67,12 @@ npm-debug.log* /.skypagestmp webdriver-screenshotslocal* browserstack.err -/skyux-spa-visual-tests/dist/ -/skyux-spa-visual-tests/node_modules/ + browserstack-binary/BrowserStackLocal + +skyux-spa-visual-tests/dist +skyux-spa-visual-tests/node_modules +skyux-spa-visual-tests/screenshots-baseline-local +skyux-spa-visual-tests/screenshots-diff-local +skyux-spa-visual-tests/screenshots-created-local + diff --git a/.travis.yml b/.travis.yml index 7a5d42261..1fd0d0344 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,11 +1,13 @@ language: node_js node_js: - - "6.1" + - "6.10.3" # https://docs.travis-ci.com/user/customizing-the-build/#Git-Clone-Depth git: depth: 10 +sudo: required + # https://docs.travis-ci.com/user/languages/javascript-with-nodejs#Node.js-v4-(or-io.js-v3)-compiler-requirements addons: apt: @@ -32,6 +34,11 @@ before_install: - chmod +x ./scripts/visual-baseline.sh - chmod +x ./scripts/visual-failures.sh +after_install: + + - sudo cp .node_modules/@blackbaud/skyux-builder/ssl/skyux-ca.crt /usr/local/share/ca-certificates/skyux-ca.crt + - sudo update-ca-certificates + script: ./scripts/travis-script.sh after_script: ./scripts/travis-after-script.sh after_success: diff --git a/CHANGELOG.md b/CHANGELOG.md index c0133ccaa..5c0604e01 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,13 +1,45 @@ +# 2.0.0-rc.4 (2017-06-24) + + - Fix npm release error. + +# 2.0.0-rc.3 (2017-06-24) + + - Added keyboard support for tab component. (#188) (Thanks @Blackbaud-SandhyaRajasabeson) + - Added animation polyfill for increased browser support. (#803) (Thanks @Blackbaud-SandhyaRajasabeson) + - Added text highlight directive. (#775) + + ### Library updates + + - Added support for Angular 4.2.5 to fix some angular animation issues, see https://github.com/angular/angular/blob/master/CHANGELOG.md for more information. + +# 2.0.0-rc.2 (2017-06-23) + +- All the updates for 2.0.0-beta.33. +- Added support for SKY UX Builder 1.0.0-rc.3. + # 2.0.0-beta.33 (2017-06-23) - Added the SkyNumeric Pipe. (#764) (Thanks @Blackbaud-AdamSc) - Added the email validation directive. (#379) (Thanks @Blackbaud-SandhyaRajasabeson) +# 2.0.0-rc.1 (2017-06-20) + + - All the updates for 2.0.0-beta.32. + + ### Breaking changes + + - Fixed typo to change SkyTimepickerTimeOutput `ios8601` property to be `iso8601`. + # 2.0.0-beta.32 (2017-06-20) - Tweaked animation for text-expand in firefox. (#695) - Handle search when paging does not exist. (#813) +# 2.0.0-rc.0 (2017-06-16) + + - Updated dependencies to support Angular 4.1.3. (#549) See http://angularjs.blogspot.com/2017/03/angular-400-now-available.html and https://github.com/angular/angular/blob/master/CHANGELOG.md for more information. + - Updated visual test process for SKY UX 2. + # 2.0.0-beta.31 (2017-06-14) - Added ability to specify sizes for modals. (#489) (Thanks @Blackbaud-AdamHickey) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 31c348858..c36212015 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -54,23 +54,17 @@ As your tests run, code coverage results are generated and can be located under ### Write visual regression tests -During our continuous integration builds, we run visual regression tests through BrowserStack using [webdriverio](http://webdriver.io/) and [wdio-visual-regression-service](https://github.com/zinserjan/wdio-visual-regression-service). To run these tests locally, you need [GraphicsMagick](http://www.graphicsmagick.org/) for image processing installed on your system. +During our continuous integration builds, we run visual regression tests through BrowserStack using [protractor](http://www.protractortest.org/) and [pix-diff](https://github.com/koola/pix-diff). -##### Mac OS X using [Homebrew](http://mxcl.github.io/homebrew/) -```sh -$ brew install graphicsmagick -``` - -##### Ubuntu using apt-get -```sh -$ sudo apt-get install graphicsmagick -``` - -##### Windows +After you install these prerequisites, you can run the visual regression tests using `npm run test:visual`, which creates and compares screenshots in the `skyux-spa-visual-tests/screenshots-baseline-local/` folder. -Download and install executables for [GraphicsMagick](http://www.graphicsmagick.org/download.html). Make sure to install the right binaries desired for your system (32bit vs 64bit). +To create visual tests for a new component, first create a folder for the tests in `skyux-spa-visual-tests/src/app`. This folder will contain four files for the visual test: + - {componentName}-visual.component.html : The template for the component to render and screenshot. + - {componentName}-visual.component.ts : The typescript code for the component to render and screenshot. + - {componentName}.visual-spec.ts : The protractor code to run the screenshot tests. + - index.html : The route file that contains the component to render and screenshot. -After you install these prerequisites, you can run the visual regression tests using `npm run test:visual`, which creates and compares screenshots in the `webdriver-screenshotslocal` folder. +Then, in `skyux-spa-visual-tests/src/app/home.component.ts`, add the name of the test folder you just created to the `tests` array. ### Submit the code @@ -90,8 +84,6 @@ Script | Description `test` | Runs unit tests and visual regression tests. `test:unit` | Runs Karma unit tests. `test:visual` | Runs Webdriver visual regression tests. -`start` | Serves the components at [http://localhost:3000](http://localhost:3000) for debugging. -`start:visual`| Serves the visual fixtures at [http://localhost:3000](http://localhost:3000) for debugging. `watch` | Runs Karma unit tests and watch for file changes. diff --git a/config/karma/ci.karma.conf.js b/config/karma/ci.karma.conf.js index 6504f369f..1d01ce4b3 100644 --- a/config/karma/ci.karma.conf.js +++ b/config/karma/ci.karma.conf.js @@ -40,13 +40,13 @@ module.exports = function (config) { browser: 'chrome', os: 'OS X', os_version: 'Sierra' - }//, - // bs_osx_firefox_latest: { - // base: 'BrowserStack', - // browser: 'firefox', - // os: 'OS X', - // os_version: 'Sierra' - // } + }, + bs_osx_firefox_latest: { + base: 'BrowserStack', + browser: 'firefox', + os: 'OS X', + os_version: 'Sierra' + } }; config.set({ diff --git a/config/karma/shared.karma.conf.js b/config/karma/shared.karma.conf.js index 662c926fb..7aeb7c9af 100644 --- a/config/karma/shared.karma.conf.js +++ b/config/karma/shared.karma.conf.js @@ -45,6 +45,10 @@ module.exports = function (config) { browserDisconnectTimeout: 3e5, browserDisconnectTolerance: 3, browserNoActivityTimeout: 3e5, - captureTimeout: 3e5 + captureTimeout: 3e5, + browserConsoleLogOptions: { + level: 'log', + terminal: true + } }); }; diff --git a/config/rollup/rollup.config.js b/config/rollup/rollup.config.js index caa684795..dd39b7643 100644 --- a/config/rollup/rollup.config.js +++ b/config/rollup/rollup.config.js @@ -15,6 +15,7 @@ export default { '@angular/router': 'ng.router', 'ng2-dragula/ng2-dragula': 'ng2.dragula', '@angular/platform-browser-dynamic': 'ng.platformBrowserDynamic', + '@angular/platform-browser': 'ng.platformBrowser', 'moment': 'moment' }, external: [ diff --git a/config/utils/visual-browser-commands.js b/config/utils/visual-browser-commands.js deleted file mode 100644 index c01592218..000000000 --- a/config/utils/visual-browser-commands.js +++ /dev/null @@ -1,148 +0,0 @@ -(function () { - 'use strict'; - - var fs = require('fs'); - var path = require('path'); - var util = require('util'); - - function checkAccessibility(browser, options) { - return browser.executeAsync(function (done) { - - var config = { - rules: { - 'bypass': { enabled: false }, - 'color-contrast': { enabled: false } - } - }; - axe.a11yCheck(document, config, function (results) { - done(results); - }); - - }).then(function (ret) { - if (ret.value.violations && ret.value.violations.length !== 0) { - logViolations(options.screenshotName, ret.value.violations); - expect(ret.value.violations.length).toBe(0, ' number of accessiblity violations'); - } - - return; - }); - } - - function checkVisualResult(results, options, browser) { - results.forEach(function (element) { - if (!element.isWithinMisMatchTolerance) { - log('Screenshot has mismatch percentage of ' + element.misMatchPercentage); - } - - expect(element.isWithinMisMatchTolerance).toBe(true); - }); - - if (options.checkAccessibility) { - return checkAccessibility(browser, options); - } else { - return; - } - } - - function getViewSizeHandler(width, browser, options) { - var widthString = '.' + width + 'px'; - - options.screenshotName = - options.screenshotName + '_full' + '.' + options.screenshotName + widthString; - - return browser.checkElement( - options.selector, - { - screenshotName: options.screenshotName - }).then(function (results) { - return checkVisualResult(results, options, this); - }); - } - - function compareScreenshot(browser, options) { - return browser.getViewportSize('width').then(function (width) { - return getViewSizeHandler(width, this, options); - }); - } - - function getPrefix(desiredCapabilities) { - return desiredCapabilities.os + '_' + desiredCapabilities.browserName; - } - - function log(message) { - console.log('\x1b[31m', message); - } - - function logViolations(name, violations) { - log(util.format( - '\nThe following accessibility issues exist in %s:\n', - name - )); - - violations.forEach(function (violation) { - log(' violation at: ' + violation.help); - violation.nodes.forEach(function (line) { - log(line.target); - }); - - log('More Information: ' + violation.helpUrl); - }); - } - - function focusElement(browser, selector) { - return browser.execute('document.querySelector("' + selector + '").focus()'); - } - - function moveCursorOffScreen(browser) { - return browser.moveToObject('body', 0, 0); - } - - function setupTest(browser, url, screenWidth) { - return browser - .url(url) - .getViewportSize() - .then(function (size) { - if (size.width !== screenWidth) { - return browser.setViewportSize({ - height: size.height, - width: screenWidth - }); - } else { - return; - } - }); - } - - function getScreenshotName(basePath) { - return function (context) { - var prefix = getPrefix(context.desiredCapabilities); - var screenshotName = context.options.screenshotName; - - screenshotName = prefix + '_' + screenshotName + '.baseline.png'; - - return path.join(basePath, prefix, screenshotName); - }; - } - - function getVisualRegression(referenceFolder, screenshotFolder, diffsFolder) { - var VisualRegressionCompare = require('wdio-visual-regression-service/compare'); - return { - compare: new VisualRegressionCompare.LocalCompare({ - referenceName: getScreenshotName(path.join(process.cwd(), referenceFolder)), - screenshotName: getScreenshotName(path.join(process.cwd(), screenshotFolder)), - diffName: getScreenshotName(path.join(process.cwd(), diffsFolder)), - misMatchTolerance: 1.5 - }), - viewportChangePause: 300 - }; - } - - module.exports = { - compareScreenshot: compareScreenshot, - focusElement: focusElement, - moveCursorOffScreen: moveCursorOffScreen, - setupTest: setupTest, - getVisualRegression: getVisualRegression - }; - -})(); diff --git a/config/utils/visual-server.js b/config/utils/visual-server.js deleted file mode 100644 index 3c2678692..000000000 --- a/config/utils/visual-server.js +++ /dev/null @@ -1,111 +0,0 @@ -(function () { - 'use strict'; - - var browserstack = require('browserstack-local'); - var rimraf = require('rimraf'); - var selenium = require('selenium-standalone'); - var webpack = require('webpack'); - var WebpackDevServer = require('webpack-dev-server'); - var webpackConfig = require('../webpack/webpack.visual'); - - // Remove ForkCheckerPlugin as it hangs the server - var webpackCompiler = webpack(webpackConfig); - webpackCompiler.options.plugins.shift(); - - var server = new WebpackDevServer(webpackCompiler, { - noInfo: true, - 'content-base': 'src/' - }); - - var bsLocal; - var seleniumChild; - - // Start the webserver - function start() { - return new Promise(function (resolve, reject) { - return server.listen(webpackCompiler.options.devServer.port, function () { - return selenium.install({ - logger: console.log - }, function () { - return selenium.start(function (err, child) { - seleniumChild = child; - resolve(); - }); - }); - }); - }); - } - - function startCI() { - return new Promise(function (resolve, reject) { - //bsLocal = new browserstack.Local(); - return server.listen(webpackCompiler.options.devServer.port, function () { - /*return bsLocal.start({ - key: process.env.BROWSER_STACK_ACCESS_KEY, - onlyAutomate: true, - forcelocal: true, - force: true - //localIdentifier: 'SKYUX2BROWSERSTACK', - //parallelRuns: '30' - //binarypath: process.env.BROWSER_STACK_BINARY_BASE_PATH - }, function (err) { - if (err) { - reject(err); - } else { - resolve(); - } - });*/ - console.log('starting server'); - return resolve(); - }); - }); - } - - // Stop the server and remove unused screenshots - function stop(exitCode) { - server.close(); - rimraf.sync('webdriver-screenshots*/**/*+(full|regression).png', {}); - if (seleniumChild) { - seleniumChild.kill(); - } - } - - // Stop the server and remove unused screenshots - function stopCI(exitCode) { - server.close(); - rimraf.sync('webdriver-screenshots*/**/*+(full|regression).png', {}); - if (bsLocal && bsLocal.isRunning()) { - bsLocal.stop(); - } - - } - - process.on('SIGINT', function () { - stop(); - if (bsLocal && bsLocal.isRunning()) { - bsLocal.stop(); - } - - process.exit(1); - }); - - var exports = { - start: start, - startCI: startCI, - stop: stop, - stopCI: stopCI - }; - - // Support running running commands from arguments - process.argv.forEach(function (arg) { - Object.keys(exports).forEach(function (key) { - if (arg === key) { - exports[key](); - } - }); - }); - - // Support being required in config - module.exports = exports; - -})(); diff --git a/config/wdio/ci.wdio.conf.js b/config/wdio/ci.wdio.conf.js deleted file mode 100644 index 487e42f1c..000000000 --- a/config/wdio/ci.wdio.conf.js +++ /dev/null @@ -1,63 +0,0 @@ -/* global require, exports, process */ - -(function () { - 'use strict'; - - var server = require('../utils/visual-server'); - var config = require('./shared.wdio.conf'); - - config.user = process.env.BROWSER_STACK_USERNAME; - config.key = process.env.BROWSER_STACK_ACCESS_KEY; - config.capabilities = [ - { - browserName: 'chrome', - browser_version: '57', - 'browserstack.local': 'true', - 'browserstack.debug': 'true', - os: 'OS X', - os_version: 'El Capitan', - browserDisconnectTimeout: 3e5, - browserDisconnectTolerance: 3, - browserNoActivityTimeout: 3e5, - captureTimeout: 3e5, - build: 'skyux2-mac-chrome-webdriver-' + process.env.TRAVIS_BUILD_NUMBER, - resolution: '1280x960', - name: 'SKYUX2BROWSERSTACKCI', - 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKCI' - }, - // { - // browserName: 'firefox', - // browser_version: '52', - // 'browserstack.local': 'true', - // 'browserstack.debug': 'true', - // os: 'OS X', - // os_version: 'El Capitan', - // browserDisconnectTimeout: 3e5, - // browserDisconnectTolerance: 3, - // browserNoActivityTimeout: 3e5, - // captureTimeout: 3e5, - // build: 'skyux2-mac-firefox-webdriver-' + process.env.TRAVIS_BUILD_NUMBER, - // resolution: '1280x960', - // name: 'SKYUX2BROWSERSTACKCI', - // 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKCI' - - // } - ]; - config.host = 'hub.browserstack.com'; - config.port = 80; - - config.maxInstances = 4; - - config.visualRegression = require('../utils/visual-browser-commands') - .getVisualRegression( - 'webdriver-screenshots', - 'webdriver-screenshots-screen', - 'webdriver-screenshots-diffs' - ); - - config.onPrepare = server.startCI; - config.onComplete = server.stopCI; - - exports.config = config; - -})(); diff --git a/config/wdio/local-browserstack.wdio.conf.js b/config/wdio/local-browserstack.wdio.conf.js deleted file mode 100644 index cffc08c1b..000000000 --- a/config/wdio/local-browserstack.wdio.conf.js +++ /dev/null @@ -1,63 +0,0 @@ -/* global require, exports, process */ - -(function () { - 'use strict'; - - var server = require('../utils/visual-server'); - var shared = require('./shared.wdio.conf.js'); - var timestamp = new Date().toString(); - - shared.user = process.env.BROWSER_STACK_USERNAME; - shared.key = process.env.BROWSER_STACK_ACCESS_KEY; - shared.capabilities = [ - { - browserName: 'chrome', - browser_version: '57', - 'browserstack.local': 'true', - 'browserstack.debug': 'true', - os: 'OS X', - os_version: 'El Capitan', - browserDisconnectTimeout: 3e5, - browserDisconnectTolerance: 3, - browserNoActivityTimeout: 3e5, - captureTimeout: 3e5, - build: 'skyux2-mac-chrome-webdriver-local-' + timestamp, - resolution: '1280x960', - name: 'SKYUX2BROWSERSTACKCI', - 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKCI' - }, - // { - // browserName: 'firefox', - // browser_version: '49', - // 'browserstack.selenium_version': '3.2.0', - // 'browserstack.local': 'true', - // 'browserstack.debug': 'true', - // os: 'OS X', - // os_version: 'El Capitan', - // browserDisconnectTimeout: 3e5, - // browserDisconnectTolerance: 3, - // browserNoActivityTimeout: 3e5, - // captureTimeout: 3e5, - // build: 'skyux2-mac-firefox-webdriver-local' + timestamp, - // resolution: '1280x960', - // name: 'SKYUX2BROWSERSTACKCI', - // 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKCI', - // } - ]; - shared.host = 'hub.browserstack.com'; - shared.port = 80; - shared.maxInstances = 4; - - shared.visualRegression = require('../utils/visual-browser-commands') - .getVisualRegression( - 'webdriver-screenshotslocal', - 'webdriver-screenshotslocal-screen', - 'webdriver-screenshotslocal-diffs' - ); - - shared.onPrepare = server.startCI; - shared.onComplete = server.stopCI; - - exports.config = shared; - -})(); diff --git a/config/wdio/local.wdio.conf.js b/config/wdio/local.wdio.conf.js deleted file mode 100644 index 27dcb9df5..000000000 --- a/config/wdio/local.wdio.conf.js +++ /dev/null @@ -1,28 +0,0 @@ -/* global require, exports, process */ - -(function () { - 'use strict'; - - var server = require('../utils/visual-server'); - var config = require('./shared.wdio.conf'); - - config.capabilities = [ - { - browserName: 'chrome', - os: process.platform === 'win32' ? 'WIN' : 'MAC' - } - ]; - - config.visualRegression = require('../utils/visual-browser-commands') - .getVisualRegression( - 'webdriver-screenshotslocal', - 'webdriver-screenshotslocal-screen', - 'webdriver-screenshotslocal-diffs' - ); - config.onPrepare = server.start; - config.onComplete = server.stop; - - config.maxInstances = 1; - - exports.config = config; -})(); diff --git a/config/wdio/shared.wdio.conf.js b/config/wdio/shared.wdio.conf.js deleted file mode 100644 index fd617fa92..000000000 --- a/config/wdio/shared.wdio.conf.js +++ /dev/null @@ -1,64 +0,0 @@ -/** - * WebDriver configuration options shared between CI and local versions. - */ - -(function () { - 'use strict'; - - var timestamp; - module.exports = { - specs: [ - 'src/modules/**/*.visual-spec.js' - ], - logLevel: 'silent', - baseUrl: 'http://localhost:3000', - framework: 'jasmine', - jasmineNodeOpts: { - defaultTimeoutInterval: 200000, - expectationResultHandler: function () { } - }, - waitforTimeout: 3000, - services: [ - 'visual-regression' - ], - - before: function () { - timestamp = new Date().getTime(); - var commands = require('../utils/visual-browser-commands'); - /*Object.keys(commands).forEach(function (command) { - browser.addCommand(command, function async() { - var args = Array.from(arguments); - args.unshift(this); - commands[command].apply(this, args); - }); - });*/ - browser.addCommand('setupTest', function async(url, screenWidth) { - return commands.setupTest(this, url, screenWidth || 1280); - }); - - browser.addCommand('compareScreenshot', function async(options) { - return commands.compareScreenshot(this, options); - }); - - browser.addCommand('moveCursorOffScreen', function async() { - return commands.moveCursorOffScreen(this); - }); - - browser.addCommand('focusElement', function async(selector) { - return commands.focusElement(this, selector); - }); - - }, - - beforeTest: function () { - - }, - - after: function () { - - }, - - sync: false - }; - -})(); diff --git a/config/webpack/webpack.common.js b/config/webpack/webpack.common.js index 577efdd2b..621fe0d3d 100644 --- a/config/webpack/webpack.common.js +++ b/config/webpack/webpack.common.js @@ -4,7 +4,6 @@ const helpers = require('../utils/helpers'); const ExtractTextPlugin = require('extract-text-webpack-plugin'); const ContextReplacementPlugin = require('webpack/lib/ContextReplacementPlugin'); const IgnorePlugin = require('webpack/lib/IgnorePlugin'); -const ForkCheckerPlugin = require('awesome-typescript-loader').ForkCheckerPlugin; const extractScss = new ExtractTextPlugin('sky.css'); @@ -27,6 +26,11 @@ module.exports = { modules: [helpers.root('src'), 'node_modules'] }, + resolveLoader: { + modules: [ + helpers.root('node_modules') + ] + }, module: { @@ -37,8 +41,9 @@ module.exports = { loader: 'source-map-loader', exclude: [ // these packages have problems with their sourcemaps + // https://github.com/angular-redux/store/issues/64 helpers.root('node_modules/rxjs'), - helpers.root('node_modules/@angular/compiler/bundles') + helpers.root('node_modules/@angular/compiler') ] }, @@ -100,15 +105,13 @@ module.exports = { extractScss, - new ForkCheckerPlugin(), - new webpack.optimize.CommonsChunkPlugin({ name: helpers.reverse(['polyfills', 'vendor']) }), new ContextReplacementPlugin( // The (\\|\/) piece accounts for path separators in *nix and Windows - /angular(\\|\/)core(\\|\/)(esm(\\|\/)src|src)(\\|\/)linker/, + /angular(\\|\/)core(\\|\/)@angular/, helpers.root('src') // location of your src ), new IgnorePlugin(/^\.\/locale$/, /moment$/) diff --git a/config/webpack/webpack.demo-visual.js b/config/webpack/webpack.demo-visual.js deleted file mode 100644 index 21e982685..000000000 --- a/config/webpack/webpack.demo-visual.js +++ /dev/null @@ -1,44 +0,0 @@ -var HtmlWebpackPlugin = require('html-webpack-plugin'); -var helpers = require('../utils/helpers'); -var glob = require('glob'); -var path = require('path'); -var plugins = []; -var entry = {}; - -(function () { - var files = glob.sync('./src/modules/**/fixtures/*.component.visual-fixture.ts'); - - files.forEach(function (file) { - var demoName; - var dirname; - var parts; - - dirname = path.dirname(file); - parts = dirname.split('/'); // glob always returns '/' as separator - demoName = parts[parts.length - 2]; - entry[demoName] = file; - - plugins.push(new HtmlWebpackPlugin({ - template: 'visual/index.html', - chunks: ['polyfills', 'vendor', demoName], - chunksSortMode: helpers.packageSort(['polyfills', 'vendor', demoName]), - filename: demoName + '.html' - })); - }); - - // Create landing page for easier debugging - plugins.push(new HtmlWebpackPlugin({ - inject: false, - entry: entry, - template: 'visual/index.ejs', - filename: 'index.html' - })); - -}()); - -exports.buildVisualConfig = function () { - return { - entry: entry, - plugins: plugins - }; -}; diff --git a/config/webpack/webpack.releases.js b/config/webpack/webpack.releases.js index 59f61854c..f2c257968 100644 --- a/config/webpack/webpack.releases.js +++ b/config/webpack/webpack.releases.js @@ -41,7 +41,7 @@ module.exports = webpackMerge(commonConfig, { }, output: { filename: '[name].js', - path: 'releases' + path: path.resolve(__dirname, '..', '..', 'releases') }, plugins: [ PrepareFallback, diff --git a/config/webpack/webpack.test.js b/config/webpack/webpack.test.js index e571cfb2f..4e78f2334 100644 --- a/config/webpack/webpack.test.js +++ b/config/webpack/webpack.test.js @@ -103,7 +103,7 @@ module.exports = { new ContextReplacementPlugin( // The (\\|\/) piece accounts for path separators in *nix and Windows - /angular(\\|\/)core(\\|\/)(esm(\\|\/)src|src)(\\|\/)linker/, + /angular(\\|\/)core(\\|\/)@angular/, helpers.root('src') // location of your src ), diff --git a/config/webpack/webpack.visual.js b/config/webpack/webpack.visual.js deleted file mode 100644 index c2339d6dc..000000000 --- a/config/webpack/webpack.visual.js +++ /dev/null @@ -1,157 +0,0 @@ -/** - * @author: @AngularClass - */ - -var helpers = require('../utils/helpers'); -var webpackMerge = require('webpack-merge'); // used to merge webpack configs -var commonConfig = require('./webpack.common.js'); // the settings that are common to prod and dev -var visualConfig = require('./webpack.demo-visual.js'); - -/** - * Webpack Plugins - */ -var DefinePlugin = require('webpack/lib/DefinePlugin'); -var HtmlWebpackPlugin = require('html-webpack-plugin'); - -/** - * Webpack Constants - */ -var ENV = process.env.ENV = process.env.NODE_ENV = 'development'; -var HMR = helpers.hasProcessFlag('hot'); -var METADATA = webpackMerge(commonConfig.metadata, { - host: 'localhost', - port: 3000, - ENV: ENV, - HMR: HMR -}); - -/** - * Webpack configuration - * - * See: http://webpack.github.io/docs/configuration.html#cli - */ -module.exports = webpackMerge(commonConfig, visualConfig.buildVisualConfig(), { - - /** - * Developer tool to enhance debugging - * - * See: http://webpack.github.io/docs/configuration.html#devtool - * See: https://github.com/webpack/docs/wiki/build-performance#sourcemaps - */ - devtool: 'cheap-module-eval-source-map', - - /** - * Options affecting the output of the compilation. - * - * See: http://webpack.github.io/docs/configuration.html#output - */ - output: { - - /** - * The output directory as absolute path (required). - * - * See: http://webpack.github.io/docs/configuration.html#output-path - */ - path: helpers.root('visual/'), - - /** - * Specifies the name of each output file on disk. - * IMPORTANT: You must not specify an absolute path here! - * - * See: http://webpack.github.io/docs/configuration.html#output-filename - */ - filename: '[name].bundle.js', - - /** - * The filename of the SourceMaps for the JavaScript files. - * They are inside the output.path directory. - * - * See: http://webpack.github.io/docs/configuration.html#output-sourcemapfilename - */ - sourceMapFilename: '[name].map', - - /** The filename of non-entry chunks as relative path - * inside the output.path directory. - * - * See: http://webpack.github.io/docs/configuration.html#output-chunkfilename - */ - chunkFilename: '[id].chunk.js' - - }, - - plugins: [ - - /** - * Plugin: DefinePlugin - * Description: Define free variables. - * Useful for having development builds with debug logging or adding global constants. - * - * Environment helpers - * - * See: https://webpack.github.io/docs/list-of-plugins.html#defineplugin - */ - // NOTE: when adding more properties, make sure you include them in custom-typings.d.ts - new DefinePlugin({ - 'ENV': JSON.stringify(METADATA.ENV), - 'HMR': METADATA.HMR, - 'process.env': { - 'ENV': JSON.stringify(METADATA.ENV), - 'NODE_ENV': JSON.stringify(METADATA.ENV), - 'HMR': METADATA.HMR, - } - }), - - /* - * Plugin: HtmlWebpackPlugin - * Description: Simplifies creation of HTML files to serve your webpack bundles. - * This is especially useful for webpack bundles that include a hash in the filename - * which changes every compilation. - * - * See: https://github.com/ampedandwired/html-webpack-plugin - */ - // new HtmlWebpackPlugin({ - // template: 'demo/index.html', - // chunksSortMode: helpers.packageSort(['polyfills', 'vendor', 'demo']) - // }) - ], - - /** - * Webpack Development Server configuration - * Description: The webpack-dev-server is a little node.js Express server. - * The server emits information about the compilation state to the client, - * which reacts to those events. - * - * See: https://webpack.github.io/docs/webpack-dev-server.html - */ - devServer: { - port: METADATA.port, - host: METADATA.host, - historyApiFallback: true, - watchOptions: { - aggregateTimeout: 300, - poll: 1000 - }, - headers: { - 'Connection': 'keep-alive' - } - }, - - /* - * Include polyfills or mocks for various node stuff - * Description: Node configuration - * - * See: https://webpack.github.io/docs/configuration.html#node - */ - node: { - global: true, - crypto: 'empty', - process: true, - module: false, - clearImmediate: false, - setImmediate: false - }, - performance: { - hints: false - } - -}); diff --git a/package.json b/package.json index 7f9087dfe..07f4fd7d5 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@blackbaud/skyux", - "version": "2.0.0-beta.33", + "version": "2.0.0-rc.4", "description": "SKY UX built on Angular 2", "author": "Blackbaud, Inc.", "homepage": "https://github.com/blackbaud/skyux2", @@ -13,7 +13,7 @@ "ci": "npm run lint && npm run test:ci && npm run build", "build": "npm run clean:srctemp && node config/utils/stage-ts.js && cd .srctemp && ../node_modules/.bin/ngc && cd ../ && npm run compile:sass && cd config/rollup && ../../node_modules/.bin/rollup -c rollup.config.js && ../../node_modules/.bin/rollup -c rollup.min.config.js && npm run clean:srctemp", "clean": "rimraf -- dist", - "clean:full": "npm cache clean && rimraf -- node_modules doc coverage dist .srctemp webdriver-screenshotslocal webdriver-screenshotslocal-diffs", + "clean:full": "npm cache clean && rimraf -- node_modules doc coverage dist .srctemp webdriver-screenshotslocal webdriver-screenshotslocal-diffs skyux-spa-visual-tests/node_modules/ skyux-spa-visual-tests/dist/", "clean:releases": "rimraf -- releases", "clean:srctemp": "rimraf -- .srctemp", "compile:sass": "./node_modules/node-sass/bin/node-sass src/scss/sky.scss dist/css/sky.css", @@ -23,106 +23,104 @@ "test:unit": "npm run test:unit:base -- config/karma/local.karma.conf.js", "test:unit:ci": "npm run test:unit:base -- config/karma/ci.karma.conf.js", "test:unit:base": "node --max-old-space-size=4096 node_modules/karma/bin/karma start", - "test:visual": "npm run test:visual:base -- config/wdio/local.wdio.conf.js", - "test:visual:ci": "./scripts/browserstack-local-start.sh && npm run test:visual:base -- config/wdio/ci.wdio.conf.js", - "test:visual:local-browserstack": "./scripts/browserstack-local-start.sh && npm run test:visual:base -- config/wdio/local-browserstack.wdio.conf.js", - "test:visual:base": "./node_modules/.bin/wdio", + "test:visual": "cd skyux-spa-visual-tests && npm run build-visual && npm run test-visual:local", + "test:visual:ci": "cd skyux-spa-visual-tests && npm run build-visual && npm run test-visual:ci", + "test:visual:local-browserstack": "cd skyux-spa-visual-tests && npm run build-visual && npm run test-visual:local-browserstack", "postversion": "git push && git push --tags", "prebuild": "npm run clean", "pretest": "npm run lint", "preversion": "npm test", - "releases": "npm run clean:releases && ./node_modules/.bin/webpack --progress --config config/webpack/webpack.releases.js", + "releases": "npm run clean:releases && ./node_modules/.bin/webpack --progress --config ./config/webpack/webpack.releases.js", "start": "webpack-dev-server --config config/webpack/webpack.dev.js --inline --progress --profile --watch --content-base src/", "start:visual": "node ./config/utils/visual-server.js start", "version": "npm run build", "watch": "npm run test:unit -- --auto-watch --no-single-run" }, + "peerDependencies": { + "@blackbaud/stache": "2.0.0-beta.8" + }, "dependencies": { - "@angular/common": "2.4.8", - "@angular/compiler": "2.4.8", - "@angular/core": "2.4.8", - "@angular/forms": "2.4.8", - "@angular/platform-browser": "2.4.8", - "@angular/platform-browser-dynamic": "2.4.8", - "@angular/router": "3.4.8", - "@blackbaud/stache": "2.0.0-beta.0", + "@angular/animations": "4.2.5", + "@angular/common": "4.2.5", + "@angular/compiler": "4.2.5", + "@angular/core": "4.2.5", + "@angular/forms": "4.2.5", + "@angular/platform-browser": "4.2.5", + "@angular/platform-browser-dynamic": "4.2.5", + "@angular/router": "4.2.5", "core-js": "2.4.1", "dragula": "3.7.2", "font-awesome": "4.7.0", "intl": "1.2.5", - "ng2-dragula": "1.2.2-0", - "ng2-toastr": "0.3.1", - "rxjs": "5.1.0", - "zone.js": "0.7.6", "microedge-rxstate": "1.0.3", - "moment": "2.17.1" + "moment": "2.18.1", + "ng2-dragula": "1.3.1", + "ng2-toastr": "4.0.1", + "rxjs": "5.4.0", + "zone.js": "0.8.10", + "web-animations-js": "2.2.5" }, "devDependencies": { - "@angular/compiler-cli": "2.4.8", - "@blackbaud/skyux-builder": "1.0.0-beta.31", - "@types/core-js": "0.9.35", - "@types/jasmine": "2.5.41", - "@types/node": "6.0.45", - "@types/webpack": "2.2.4", - "angular2-template-loader": "0.6.0", - "awesome-typescript-loader": "2.2.4", + "@angular/compiler-cli": "4.2.5", + "@blackbaud/skyux-builder": "1.0.0-rc.5", + "@blackbaud/stache": "2.0.0-beta.7", + "@types/core-js": "0.9.41", + "@types/jasmine": "2.5.47", + "@types/node": "7.0.18", + "@types/webpack": "2.2.15", + "angular2-template-loader": "0.6.2", + "awesome-typescript-loader": "3.1.3", "axe-core": "1.1.1", - "base64-image-loader": "1.0.0", - "browserstack-local": "1.2.0", - "codelyzer": "1.0.0-beta.3", - "css-loader": "0.26.1", - "express": "4.14.0", - "extract-text-webpack-plugin": "2.0.0-beta.4", - "file-loader": "0.9.0", - "font-awesome-webpack": "0.0.4", - "fontfaceobserver": "2.0.5", - "fs-extra": "0.30.0", - "glob": "7.1.0", - "html-webpack-plugin": "2.24.0", - "http-server": "0.9.0", - "istanbul-instrumenter-loader": "0.1.0", - "jasmine": "2.5.2", + "base64-image-loader": "1.2.0", + "codelyzer": "3.0.1", + "css-loader": "0.28.1", + "express": "4.15.2", + "extract-text-webpack-plugin": "2.1.0", + "file-loader": "0.11.1", + "font-awesome-webpack": "0.0.5-beta.2", + "fontfaceobserver": "2.0.9", + "fs-extra": "3.0.1", + "glob": "7.1.1", + "html-webpack-plugin": "2.28.0", + "http-server": "0.10.0", + "istanbul-instrumenter-loader": "2.0.0", + "jasmine": "2.6.0", "json-loader": "0.5.4", - "karma": "1.3.0", - "karma-browserstack-launcher": "1.1.1", - "karma-chrome-launcher": "2.0.0", + "karma": "1.7.0", + "karma-browserstack-launcher": "1.2.0", + "karma-chrome-launcher": "2.1.1", "karma-firefox-launcher": "1.0.1", "karma-coverage": "1.1.1", - "karma-jasmine": "1.0.2", - "karma-mocha-reporter": "2.2.0", + "karma-jasmine": "1.1.0", + "karma-mocha-reporter": "2.2.3", "karma-sourcemap-loader": "0.3.7", - "karma-webpack": "1.8.0", - "less": "2.7.1", - "node-resemble-js": "0.1.1", - "node-sass": "3.10.1", + "karma-webpack": "2.0.3", + "less": "2.7.2", + "node-resemble-js": "0.2.0", + "node-sass": "4.5.3", "normalize-scss": "5.0.3", - "prismjs": "1.5.1", + "prismjs": "1.6.0", "raw-loader": "0.5.1", "remap-istanbul": "0.9.5", - "rimraf": "2.5.4", - "rollup": "0.35.9", - "rollup-plugin-commonjs": "7.0.0", - "rollup-plugin-node-resolve": "2.0.0", - "rollup-plugin-uglify": "1.0.1", - "sass-loader": "6.0.3", - "selenium-standalone": "6.1.0", + "rimraf": "2.6.1", + "rollup": "0.41.6", + "rollup-plugin-commonjs": "8.0.2", + "rollup-plugin-node-resolve": "3.0.0", + "rollup-plugin-uglify": "1.0.2", + "sass-loader": "6.0.5", + "selenium-standalone": "6.4.1", "source-map-inline-loader": "blackbaud-bobbyearl/source-map-inline-loader", - "source-map-loader": "0.1.5", - "style-loader": "0.16.1", + "source-map-loader": "0.2.1", + "style-loader": "0.17.0", "ts-helpers": "1.1.2", - "tslint": "3.15.1", - "tslint-loader": "2.1.5", - "typescript": "2.0.6", - "url-loader": "0.5.7", - "wdio-jasmine-framework": "0.2.5", - "wdio-selenium-standalone-service": "0.0.8", - "wdio-spec-reporter": "0.0.3", - "wdio-visual-regression-service": "0.7.0", - "webdriverio": "4.8.0", - "webpack": "2.2.0-rc.1", - "webpack-dev-middleware": "1.7.0", - "webpack-dev-server": "2.1.0-beta.9", - "webpack-merge": "0.15.0" + "tslint": "5.2.0", + "tslint-loader": "3.5.3", + "typescript": "2.3.2", + "url-loader": "0.5.8", + "webpack": "2.5.1", + "webpack-dev-middleware": "1.10.2", + "webpack-dev-server": "2.4.5", + "webpack-merge": "4.1.0" }, "repository": { "type": "git", diff --git a/scripts/browserstack-local-start.sh b/scripts/browserstack-local-start.sh index 63b0db808..a6d438d4e 100755 --- a/scripts/browserstack-local-start.sh +++ b/scripts/browserstack-local-start.sh @@ -1,2 +1,2 @@ # Assumes the binary is created and stored via the karma process. - $BROWSER_STACK_BINARY_BASE_PATH/BrowserStackLocal --key $BROWSER_STACK_ACCESS_KEY --only-automate --force-local --force --local-identifier SKYUX2BROWSERSTACKCI --parallel-runs 10 & sleep 3 +$BROWSER_STACK_BINARY_BASE_PATH/BrowserStackLocal --key $BROWSER_STACK_ACCESS_KEY --only-automate --force-local --force --local-identifier SKYUX2BROWSERSTACKCI --parallel-runs 25 & sleep 3 diff --git a/scripts/travis-script.sh b/scripts/travis-script.sh index c133fbb90..0a9d0c246 100644 --- a/scripts/travis-script.sh +++ b/scripts/travis-script.sh @@ -4,7 +4,18 @@ set -e # Necessary to stop pull requests from forks from running outside of Savage # Override default of `npm test` if [ "$TRAVIS_SECURE_ENV_VARS" == "true" ]; then - npm run ci && skyux build && ./scripts/visual-baseline.sh + # Remove duplicate libraries due to circular dependency: + rimraf ./node_modules/@blackbaud/skyux/node_modules/@angular + rimraf ./node_modules/@blackbaud/skyux/node_modules/@blackbaud + rimraf ./node_modules/@blackbaud/skyux-builder/node_modules/@angular + rimraf ./node_modules/@blackbaud/stache/node_modules/@angular + + ./scripts/browserstack-cleanup.sh + npm run ci + + skyux build + ./scripts/visual-baseline.sh + else echo -e "Pull requests from forks are run via Savage." fi diff --git a/scripts/visual-baseline.sh b/scripts/visual-baseline.sh index 7400ea36c..0015ce62d 100644 --- a/scripts/visual-baseline.sh +++ b/scripts/visual-baseline.sh @@ -9,13 +9,24 @@ if [[ "$TRAVIS_PULL_REQUEST" == "false" && ! $TRAVIS_BRANCH =~ $SAVAGE_BRANCH ]] git config --global user.name "Blackbaud Sky Build User" git clone --quiet --branch=$TRAVIS_BRANCH https://${GH_TOKEN}@github.com/blackbaud/skyux2.git skyux2 > /dev/null - cp -rf webdriver-screenshots/ skyux2/ - cd skyux2 + ls + + echo -e "Changing directory to skyux-spa-visual-tests" + + cd skyux-spa-visual-tests + + ls + + cp -rf screenshots-baseline/ ../skyux2/skyux-spa-visual-tests/ + + echo -e "Changing directory to skyux 2" + + cd ../skyux2 if [ -z "$(git ls-files --others --exclude-standard)" ]; then echo -e "No changes to commit to skyux2." else - git add webdriver-screenshots/ + git add skyux-spa-visual-tests/screenshots-baseline/ git commit -m "Travis build $TRAVIS_BUILD_NUMBER pushed to skyux2 [ci skip]" git push -fq origin $TRAVIS_BRANCH > /dev/null echo -e "skyux2 successfully updated.\n" diff --git a/scripts/visual-failures.sh b/scripts/visual-failures.sh index d2c6f8e8f..c343ad151 100644 --- a/scripts/visual-failures.sh +++ b/scripts/visual-failures.sh @@ -1,7 +1,7 @@ # This file only runs if there are results from the visualtests # It's using the deploy key specified in Travis since Secure Environemnt Variables aren't available to forks. -if [[ "$(ls -A webdriver-screenshots-diffs)" ]]; then +if [[ "$(ls -A skyux-spa-visual-tests/screenshots-diff)" ]]; then echo -e "Starting to update webdriver test results.\n" @@ -17,15 +17,15 @@ if [[ "$(ls -A webdriver-screenshots-diffs)" ]]; then fi git checkout -b $branch - cp -rf ../webdriver-screenshots-screen created-screenshots/ + cp -rf ../skyux-spa-visual-tests/screenshots-created/ created-screenshots/ mkdir -p failures - cp -rf ../webdriver-screenshots-diffs/ failures/ + cp -rf ../skyux-spa-visual-tests/screenshots-diff/ failures/ mkdir -p all - cp -rf ../webdriver-screenshots/ all/ + cp -rf ../skyux-spa-visual-tests/screenshots-baseline/ all/ git add -A if [ -z "$(git status --porcelain)" ]; then diff --git a/skyux-spa-visual-tests/.editorconfig b/skyux-spa-visual-tests/.editorconfig new file mode 100644 index 000000000..9d08a1a82 --- /dev/null +++ b/skyux-spa-visual-tests/.editorconfig @@ -0,0 +1,9 @@ +root = true + +[*] +charset = utf-8 +indent_style = space +indent_size = 2 +end_of_line = lf +insert_final_newline = true +trim_trailing_whitespace = true diff --git a/skyux-spa-visual-tests/.gitignore b/skyux-spa-visual-tests/.gitignore new file mode 100644 index 000000000..39af6315f --- /dev/null +++ b/skyux-spa-visual-tests/.gitignore @@ -0,0 +1,26 @@ +# Logs +logs +*.log +npm-debug.log* + +# Coverage directory used by tools like istanbul +coverage + +# Dependency directories +node_modules +jspm_packages + +# Optional npm cache directory +.npm + +# Optional REPL history +.node_repl_history + +# SKY UX temp directory +.skyuxtmp + +# SKY UX build directory +dist + +# OS specific files +.DS_Store diff --git a/skyux-spa-visual-tests/.jshintrc b/skyux-spa-visual-tests/.jshintrc new file mode 100644 index 000000000..bf0545880 --- /dev/null +++ b/skyux-spa-visual-tests/.jshintrc @@ -0,0 +1,13 @@ +{ + "esversion": 6, + "curly": true, + "eqeqeq": true, + "forin": true, + "freeze": true, + "noarg": true, + "nonbsp": true, + "nonew": true, + "strict": true, + "undef": true, + "unused": true +} diff --git a/skyux-spa-visual-tests/.vscode/launch.json b/skyux-spa-visual-tests/.vscode/launch.json new file mode 100644 index 000000000..671aafad8 --- /dev/null +++ b/skyux-spa-visual-tests/.vscode/launch.json @@ -0,0 +1,28 @@ +{ + // Use IntelliSense to learn about possible Node.js debug attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "name": "Debug SKY UX", + "type": "node2", + "request": "launch", + "program": "${workspaceRoot}/../skyux-cli/bin/skyux.js", + "stopOnEntry": false, + "args": ["build"], + "cwd": "${workspaceRoot}", + "preLaunchTask": null, + "runtimeExecutable": null, + "runtimeArgs": [ + "--nolazy" + ], + "env": { + "NODE_ENV": "development" + }, + "console": "integratedTerminal", + "sourceMaps": false, + "outFiles": [] + } + ] +} diff --git a/skyux-spa-visual-tests/.vscode/settings.json b/skyux-spa-visual-tests/.vscode/settings.json new file mode 100644 index 000000000..94e42f182 --- /dev/null +++ b/skyux-spa-visual-tests/.vscode/settings.json @@ -0,0 +1,7 @@ +// Place your settings in this file to overwrite default and user settings. +{ + // Columns at which to show vertical rulers + "editor.rulers": [100], + + "typescript.tsdk": "node_modules/typescript/lib" +} diff --git a/skyux-spa-visual-tests/README.md b/skyux-spa-visual-tests/README.md new file mode 100644 index 000000000..c9077dae4 --- /dev/null +++ b/skyux-spa-visual-tests/README.md @@ -0,0 +1,2 @@ +# skyux-template +Template for SKY UX applications created by the SKY UX CLI diff --git a/skyux-spa-visual-tests/config/ci.visual.conf.js b/skyux-spa-visual-tests/config/ci.visual.conf.js new file mode 100644 index 000000000..cd0d5f5bd --- /dev/null +++ b/skyux-spa-visual-tests/config/ci.visual.conf.js @@ -0,0 +1,98 @@ +/*jshint jasmine: true, node: true */ +/* global browser */ +'use strict'; + +let builderUtils = require('@blackbaud/skyux-builder/utils/host-utils'); + +const SpecReporter = require('jasmine-spec-reporter').SpecReporter; + +var config = require('./shared.visual.conf.js'); + +var browserstack = require('browserstack-local'); + +require('./utils/fast-selenium.js'); + +config.onPrepare = function () { + jasmine.getEnv().addReporter(new SpecReporter()); + const PixDiff = require('pix-diff'); + browser.pixDiff = new PixDiff( + { + basePath: 'screenshots-baseline/', + diffPath: 'screenshots-diff/', + baseline: true, + width: 1000, + height: 800 + } + ); + + browser.skyVisualTestOptions = { + createdPath: 'screenshots-created/', + createdPathDiff: 'screenshots-created-diff/' + }; + + var destination = builderUtils.resolve( + '/', + browser.params.localUrl, + JSON.parse(browser.params.chunks), + JSON.parse(browser.params.skyPagesConfig) + ); + + return browser.get(destination); +}; + +config.capabilities = { + 'browserName': 'chrome', + 'chromeOptions': { + 'args': ['--disable-extensions --ignore-certificate-errors'] + }, + 'browserstack.user': process.env.BROWSER_STACK_USERNAME, + 'browserstack.key': process.env.BROWSER_STACK_ACCESS_KEY, + browser_version: '57', + 'browserstack.local': 'true', + 'browserstack.debug': 'true', + os: 'OS X', + os_version: 'El Capitan', + browserDisconnectTimeout: 3e5, + browserDisconnectTolerance: 3, + browserNoActivityTimeout: 3e5, + captureTimeout: 3e5, + build: 'skyux2-mac-chrome-webdriver-' + process.env.TRAVIS_BUILD_NUMBER, + resolution: '1280x960', + name: 'SKYUX2BROWSERSTACKCI', + 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKCI', + 'acceptSslCerts': true +}; + +config.seleniumAddress = 'http://hub-cloud.browserstack.com/wd/hub'; + +config.beforeLaunch = function () { + require('ts-node').register({ ignore: false }); + console.log('Connecting local'); + return new Promise(function (resolve, reject){ + exports.bs_local = new browserstack.Local(); + exports.bs_local.start( + { + 'key': process.env.BROWSER_STACK_ACCESS_KEY, + onlyAutomate: true, + forceLocal: true, + force: true, + localIdentifier: 'SKYUX2BROWSERSTACKCI' + }, function (error) { + if (error) { + return reject(error); + } + + console.log('Connected. Now testing...'); + resolve(); + }); + }); +}; + +// Code to stop browserstack local after end of test +config.afterLaunch = function () { + return new Promise(function (resolve) { + exports.bs_local.stop(resolve); + }); +}; + +exports.config = config; diff --git a/skyux-spa-visual-tests/config/local-browserstack.visual.conf.js b/skyux-spa-visual-tests/config/local-browserstack.visual.conf.js new file mode 100644 index 000000000..ce36afd58 --- /dev/null +++ b/skyux-spa-visual-tests/config/local-browserstack.visual.conf.js @@ -0,0 +1,102 @@ +/*jshint jasmine: true, node: true */ +/* global browser */ +'use strict'; + +let builderUtils = require('@blackbaud/skyux-builder/utils/host-utils'); + +const SpecReporter = require('jasmine-spec-reporter').SpecReporter; + +var config = require('./shared.visual.conf.js'); + +var browserstack = require('browserstack-local'); + +require('./utils/fast-selenium.js'); + +var timestamp = new Date().toString(); + +config.onPrepare = function () { + jasmine.getEnv().addReporter(new SpecReporter()); + const PixDiff = require('pix-diff'); + browser.pixDiff = new PixDiff( + { + basePath: 'screenshots-baseline-local/', + diffPath: 'screenshots-diff-local/', + baseline: true, + width: 1000, + height: 600 + } + ); + + browser.skyVisualTestOptions = { + createdPath: 'screenshots-created-local/', + createdPathDiff: 'screenshots-created-diff-local/' + }; + + var destination = builderUtils.resolve( + '/', + browser.params.localUrl, + JSON.parse(browser.params.chunks), + JSON.parse(browser.params.skyPagesConfig) + ); + + return browser.get(destination); + +}; + +config.capabilities = { + 'browserName': 'chrome', + 'chromeOptions': { + 'args': ['--disable-extensions --ignore-certificate-errors'] + }, + 'browserstack.user': process.env.BROWSER_STACK_USERNAME, + 'browserstack.key': process.env.BROWSER_STACK_ACCESS_KEY, + browser_version: '57', + 'browserstack.local': 'true', + 'browserstack.debug': 'false', + os: 'OS X', + os_version: 'El Capitan', + browserDisconnectTimeout: 3e5, + browserDisconnectTolerance: 3, + browserNoActivityTimeout: 3e5, + captureTimeout: 3e5, + build: 'skyux2-mac-chrome-webdriver-local-' + timestamp, + resolution: '1280x960', + name: 'SKYUX2BROWSERSTACKLOCAL', + 'browserstack.localIdentifier': 'SKYUX2BROWSERSTACKLOCAL', + 'acceptSslCerts': true, + 'browserstack.video': 'false' +}; + +config.seleniumAddress = 'http://hub-cloud.browserstack.com/wd/hub'; + +config.beforeLaunch = function () { + require('ts-node').register({ ignore: false }); + console.log('Connecting local'); + return new Promise(function (resolve, reject) { + exports.bs_local = new browserstack.Local(); + exports.bs_local.start( + { + 'key': process.env.BROWSER_STACK_ACCESS_KEY, + onlyAutomate: true, + forceLocal: true, + force: true, + localIdentifier: 'SKYUX2BROWSERSTACKLOCAL' + }, function (error) { + if (error) { + return reject(error); + } + + console.log('Connected. Now testing...'); + resolve(); + }); + }); +}; + +// Code to stop browserstack local after end of test +config.afterLaunch = function () { + return new Promise(function (resolve) { + exports.bs_local.stop(resolve); + }); +}; + +exports.config = config; diff --git a/skyux-spa-visual-tests/config/local.visual.conf.js b/skyux-spa-visual-tests/config/local.visual.conf.js new file mode 100644 index 000000000..8b7374cf6 --- /dev/null +++ b/skyux-spa-visual-tests/config/local.visual.conf.js @@ -0,0 +1,49 @@ +/*jshint jasmine: true, node: true */ +/* global browser */ +'use strict'; + +let builderUtils = require('@blackbaud/skyux-builder/utils/host-utils'); + +const SpecReporter = require('jasmine-spec-reporter').SpecReporter; + +var config = require('./shared.visual.conf.js'); +config.onPrepare = function () { + jasmine.getEnv().addReporter(new SpecReporter()); + const PixDiff = require('pix-diff'); + browser.pixDiff = new PixDiff( + { + basePath: 'screenshots-baseline-local/', + diffPath: 'screenshots-diff-local/', + baseline: true, + width: 1000, + height: 800 + } + ); + + browser.skyVisualTestOptions = { + createdPath: 'screenshots-created-local/', + createdPathDiff: 'screenshots-created-diff-local/' + }; + + var destination = builderUtils.resolve( + '/', + browser.params.localUrl, + JSON.parse(browser.params.chunks), + JSON.parse(browser.params.skyPagesConfig) + ); + + return browser.get(destination); + +}; + +config.capabilities = { + 'browserName': 'chrome', + 'chromeOptions': { + 'args': ['--disable-extensions --ignore-certificate-errors'] + } +}; + +config.directConnect = true; + +exports.config = config; + diff --git a/skyux-spa-visual-tests/config/shared.visual.conf.js b/skyux-spa-visual-tests/config/shared.visual.conf.js new file mode 100644 index 000000000..d552a371e --- /dev/null +++ b/skyux-spa-visual-tests/config/shared.visual.conf.js @@ -0,0 +1,16 @@ +/*jshint jasmine: true, node: true */ +'use strict'; + +module.exports = { + useAllAngular2AppRoots: true, + beforeLaunch: function () { + require('ts-node').register({ ignore: false }); + }, + + jasmineNodeOpts: { + showColors: true, + defaultTimeoutInterval: 90000 + }, + allScriptsTimeout: 30000, + specs: ['../src/app/**/*.visual-spec.ts'] +}; diff --git a/skyux-spa-visual-tests/config/utils/fast-selenium.js b/skyux-spa-visual-tests/config/utils/fast-selenium.js new file mode 100644 index 000000000..322826658 --- /dev/null +++ b/skyux-spa-visual-tests/config/utils/fast-selenium.js @@ -0,0 +1,39 @@ +/*jslint node: true */ +'use strict'; + +/* Taken from browserstack selenium test tips at https://www.browserstack.com/automate/node */ +var http = require('http'); +var https = require('https'); + +var keepAliveTimeout = 30 * 1000; + +if (http.globalAgent && http.globalAgent.hasOwnProperty('keepAlive')) { + http.globalAgent.keepAlive = true; + https.globalAgent.keepAlive = true; + http.globalAgent.keepAliveMsecs = keepAliveTimeout; + https.globalAgent.keepAliveMsecs = keepAliveTimeout; +} else { + var agent = new http.Agent({ + keepAlive: true, + keepAliveMsecs: keepAliveTimeout + }); + + var secureAgent = new https.Agent({ + keepAlive: true, + keepAliveMsecs: keepAliveTimeout + }); + + var httpRequest = http.request; + var httpsRequest = https.request; + + http.request = function (options, callback) { + if (options.protocol === 'https:') { + options.agent = secureAgent; + return httpsRequest(options, callback); + } + else { + options.agent = agent; + return httpRequest(options, callback); + } + }; +} diff --git a/skyux-spa-visual-tests/config/utils/setup-skyux-dist.js b/skyux-spa-visual-tests/config/utils/setup-skyux-dist.js new file mode 100644 index 000000000..2c590155b --- /dev/null +++ b/skyux-spa-visual-tests/config/utils/setup-skyux-dist.js @@ -0,0 +1,10 @@ +/*jslint node: true */ +'use strict'; + +var fs = require('fs-extra'); +const path = require('path'); + +fs.ensureDirSync(path.resolve(__dirname, '../../node_modules/@blackbaud/skyux/dist')); +fs.copySync( + path.resolve(__dirname, '../../../dist'), + path.resolve(__dirname, '../../node_modules/@blackbaud/skyux/dist')); diff --git a/skyux-spa-visual-tests/config/utils/start-visual.js b/skyux-spa-visual-tests/config/utils/start-visual.js new file mode 100644 index 000000000..e0e05cae3 --- /dev/null +++ b/skyux-spa-visual-tests/config/utils/start-visual.js @@ -0,0 +1,198 @@ +/*jslint node: true */ +'use strict'; + +const config = require('@blackbaud/skyux-builder/config/sky-pages/sky-pages.config'); +const webpack = require('webpack'); +const path = require('path'); +const spawn = require('cross-spawn'); +const logger = require('winston'); +const portfinder = require('portfinder'); +const HttpServer = require('http-server'); +const selenium = require('selenium-standalone'); +const build = require('@blackbaud/skyux-builder/cli/build'); + +// Later this will change to visualtest if we do a separate command +const skyPagesConfig = config.getSkyPagesConfig('e2e'); + +// Disable this to quiet the output +const spawnOptions = { stdio: 'inherit' }; + +let httpServer; +let seleniumServer; +let start; + +let buildType = process.argv[2]; + +visualtest(skyPagesConfig, webpack); + +/** + * Spawns the necessary commands for visualtest. + * Assumes build was ran. + * @name visualtest + */ +function visualtest(skyPagesConfig, webpack) { + start = new Date().getTime(); + process.on('SIGINT', killServers); + + Promise.all([ + spawnBuild(skyPagesConfig, webpack), + spawnServer(), + spawnSelenium() + ]).then(values => { + spawnProtractor( + values[0], + values[1], + skyPagesConfig + ); + }); +} + +/** + * Function to get the protractorConfigPath + * @name getProtractorConfigPath + * @returns {string} protractorConfigPath + */ +function getProtractorConfigPath() { + return path.resolve( + 'config/' + buildType + '.visual.conf.js' + ); +} + +/** + * Handles killing off the selenium and webpack servers. + * @name killServers + */ +function killServers(exitCode) { + + logger.info('Cleaning up running servers'); + if (seleniumServer) { + logger.info('Closing selenium server'); + seleniumServer.kill(); + seleniumServer = null; + } + + if (httpServer) { + logger.info('Closing http server'); + httpServer.close(); + httpServer = null; + } + + // Catch protractor's "Kitchen Sink" error. + if (exitCode === 199) { + logger.warn('Supressing protractor\'s "kitchen sink" error 199'); + exitCode = 0; + } + + logger.info(`Execution Time: ${(new Date().getTime() - start) / 1000} seconds`); + logger.info(`Exiting process with ${exitCode}`); + process.exit(exitCode || 0); +} + +/** + * Spawns the protractor command. + * Perhaps this should be API driven? + * @name spawnProtractor + */ +function spawnProtractor(chunks, port, skyPagesConfig) { + + logger.info('Running Protractor'); + const protractorPath = path.resolve( + 'node_modules', + '.bin', + 'protractor' + ); + const protractor = spawn.spawn( + protractorPath, + [ + getProtractorConfigPath(), + `--baseUrl ${skyPagesConfig.skyux.host.url}`, + `--params.localUrl=https://localhost:${port}`, + `--params.chunks=${JSON.stringify(chunks)}`, + `--params.skyPagesConfig=${JSON.stringify(skyPagesConfig)}` + ], + spawnOptions + ); + + protractor.on('exit', killServers); +} + +/** + * Spawns the selenium server if directConnect is not enabled. + * @name spawnSelenium + */ +function spawnSelenium() { + if (buildType === 'local') { + const config = require(getProtractorConfigPath()).config; + return new Promise(resolve => { + logger.info('Spawning Selenium'); + + // Assumes we're running selenium oursevles, so we should prep it + if (config.seleniumAddress) { + selenium.install({ logger: logger.info }, () => { + selenium.start((err, child) => { + seleniumServer = child; + logger.info('Selenium server is ready.'); + resolve(); + }); + }); + + // Otherwise we need to prep protractor's selenium + } else { + const webdriverManagerPath = path.resolve( + 'node_modules', + '.bin', + 'webdriver-manager' + ); + spawn.sync(webdriverManagerPath, ['update'], spawnOptions); + logger.info('Selenium server is ready.'); + resolve(); + } + }); + } else { + return new Promise(resolve => { + resolve(); + }); + } + +} + +/** + * Spawns the httpServer + */ +function spawnServer() { + return new Promise(resolve => { + logger.info('Requesting Open Port'); + httpServer = HttpServer.createServer({ + root: 'dist/', + cors: true, + https: { + cert: + path.resolve(__dirname, '../../node_modules/@blackbaud/skyux-builder', 'ssl', 'server.crt'), + key: + path.resolve(__dirname, '../../node_modules/@blackbaud/skyux-builder', 'ssl', 'server.key') + } + }); + portfinder.getPortPromise().then(port => { + logger.info(`Open Port Found: ${port}`); + logger.info('Starting Web Server'); + httpServer.listen(port, 'localhost', () => { + logger.info('Web Server Running'); + resolve(port); + }); + }); + }); +} + +/** + * Spawns the build process. Captures the config used. + */ +function spawnBuild(skyPagesConfig, webpack) { + return new Promise(resolve => { + logger.info('Running build'); + build([], skyPagesConfig, webpack).then(stats => { + logger.info('Completed build'); + resolve(stats.toJson().chunks); + }); + }); +} + diff --git a/skyux-spa-visual-tests/config/utils/visual-test-commands.ts b/skyux-spa-visual-tests/config/utils/visual-test-commands.ts new file mode 100644 index 000000000..245527adf --- /dev/null +++ b/skyux-spa-visual-tests/config/utils/visual-test-commands.ts @@ -0,0 +1,142 @@ +import { element, by, browser} from 'protractor'; +import { SkyHostBrowser } from '@blackbaud/skyux-builder/runtime/testing/e2e'; + +const AxeBuilder = require('axe-webdriverjs'); + +let PixDiff = require('pix-diff'); + +export class SkyVisualTest { + + public static scrollElementIntoView(selector: string) { + let scrollEl = element(by.css(selector)) + browser.executeScript('arguments[0].scrollIntoView();', scrollEl.getWebElement()); + } + + public static moveCursorOffScreen() { + browser.actions() + .mouseMove(element(by.css('body')), { x: 0, y: 0}) + .perform(); + } + + public static setupTest(url: string, screenWidth?: number) { + + return browser.getCurrentUrl().then((currentUrl) => { + if (currentUrl !== 'https://host.nxt.blackbaud.com/visual-tests/') { + SkyHostBrowser.get('/'); + } + + element(by.css('a.sky-visual-test-' + url)).click(); + if (!screenWidth) { + browser.driver.manage().window().setSize(1000, 800); + } else { + browser.driver.manage().window().setSize(screenWidth, 800); + } + }); + + + } + + public static compareScreenshot(options: any) { + browser.sleep(1000); + return (browser as any).pixDiff.checkRegion( + element(by.css(options.selector)), + options.screenshotName, + { + thresholdType: PixDiff.THRESHOLD_PERCENT, + threshold: .02 + }) + .then((result: any) => { + if (result.code !== PixDiff.RESULT_SIMILAR && result.code !== PixDiff.RESULT_IDENTICAL) { + let createdPixDiff = new PixDiff({ + basePath: (browser as any).skyVisualTestOptions.createdPath, + diffPath: (browser as any).skyVisualTestOptions.createdPathDiff, + baseline: true + }); + createdPixDiff.saveRegion( + element(by.css(options.selector)), + options.screenshotName).then(() => { + browser.driver.manage().window().setSize(1000, 800); + let differencePercent = ((result.differences / result.dimension) * 100).toFixed(2); + let mismatchMessage + = 'screenshots have mismatch percentage of ' + differencePercent + ' percent' + expect(result.code === PixDiff.RESULT_SIMILAR || + result.code === PixDiff.RESULT_IDENTICAL).toBe(true, mismatchMessage); + }); + } + + browser.driver.manage().window().setSize(1000, 800); + + if (options.checkAccessibility) { + return this.checkAccessibility(); + } else { + browser.executeScript(function () { + window.history.go(-1); + }); + return Promise.resolve(); + } + + }) + .catch((error: any) => { + browser.driver.manage().window().setSize(1000, 800); + if (error.message.indexOf('saving current image') === -1) { + throw error; + } else { + if (options.checkAccessibility) { + return this.checkAccessibility(); + } else { + browser.executeScript(function () { + window.history.go(-1); + }); + return Promise.resolve(); + } + } + }); + } + + private static checkAccessibility() { + return new Promise(resolve => { + AxeBuilder(browser.driver) + .options({ + rules: { + 'bypass': { enabled: false }, + 'color-contrast': { enabled: false } + } + }) + .analyze((results: any) => { + const violations = results.violations.length; + if (violations) { + this.logAccessibilityResults(results); + browser.executeScript(function () { + window.history.go(-1); + }); + expect(violations).toBe(0, ' number of accessiblity violations'); + } + + browser.executeScript(function () { + window.history.go(-1); + }); + + resolve(); + }) + }); + } + + private static logAccessibilityResults(results: any) { + var numResults = results.violations.length; + + if (numResults > 0) { + console.error("Accessibility failure(s) found for: " + results.url + "\n"); + results.violations.forEach((result: any) => { + var label = result.nodes.length === 1 ? 'element' : 'elements'; + var msg = result.nodes.reduce(function (msg: any, node: any) { + return `${msg} Location: ${node.target[0]} + ${node.html}`; + }, "\n"); + console.error(`${result.nodes.length} ${label} failed '${result.id}' rule: ${result.help} ${msg} + Get help at: ${result.helpUrl} +`) + }); + } + } +} + diff --git a/skyux-spa-visual-tests/package.json b/skyux-spa-visual-tests/package.json new file mode 100644 index 000000000..a7ce8f685 --- /dev/null +++ b/skyux-spa-visual-tests/package.json @@ -0,0 +1,44 @@ +{ + "name": "blackbaud-skyux-spa-visual-tests", + "version": "0.0.1", + "description": "Single-page-application for skyux-spa-visual-tests", + "main": "index.js", + "engines": { + "node": ">=6.3.1" + }, + "scripts": { + "skyux": "skyux", + "test": "echo \"Error: no test specified\" && exit 1", + "build-visual": "npm install && cd .. && npm run build && node skyux-spa-visual-tests/config/utils/setup-skyux-dist.js && cd skyux-spa-visual-tests && rimraf ./node_modules/@blackbaud/skyux/node_modules/@angular && rimraf ./node_modules/@blackbaud/skyux-builder/node_modules/@angular", + "test-visual:local": "node config/utils/start-visual.js local", + "test-visual:local-browserstack": "node config/utils/start-visual.js local-browserstack", + "test-visual:ci": "node config/utils/start-visual.js ci" + }, + "keywords": [], + "author": "Blackbaud", + "license": "ISC", + "devDependencies": { + "@angular/animations": "4.1.3", + "@blackbaud/skyux": "2.0.0-rc.0", + "@blackbaud/skyux-builder": "1.0.0-rc.2", + "codelyzer": "3.0.1", + "moment": "2.18.1", + "dragula": "3.7.2", + "ng2-dragula": "1.3.1", + "microedge-rxstate": "1.0.3", + "normalize-scss": "5.0.3", + "protractor": "5.1.2", + "webpack": "2.5.1", + "portfinder": "1.0.13", + "http-server": "0.10.0", + "selenium-standalone": "6.4.1", + "pix-diff": "2.0.0", + "axe-core": "2.2.1", + "axe-webdriverjs": "1.1.1", + "browserstack-local": "1.3.0" + }, + "repository": { + "type": "git", + "url": "" + } +} diff --git a/skyux-spa-visual-tests/screenshots-baseline/action-Button-Small-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/action-Button-Small-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..2c931926e Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/action-Button-Small-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/action-Button-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/action-Button-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..5cd40dbbd Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/action-Button-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/alert-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/alert-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..7d6e52ad1 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/alert-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/avatar-Image-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/avatar-Image-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..c59fb469c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/avatar-Image-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/avatar-Initials-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/avatar-Initials-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..ecb1156f5 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/avatar-Initials-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/button-Link-Hover-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/button-Link-Hover-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..eaa05a43d Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/button-Link-Hover-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/button-Link-Inline-Hover-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/button-Link-Inline-Hover-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..e6d629c6c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/button-Link-Inline-Hover-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-All-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-All-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..1b0879d4e Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-All-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-Noactions-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-Noactions-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..2f6140c33 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-Noactions-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-Noheader-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-Noheader-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0685aec8d Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-Noheader-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-Selectable-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-Selectable-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..1af85dc8c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-Selectable-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-Selected-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-Selected-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0b9ff42ac Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-Selected-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/card-Title-Overflow-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/card-Title-Overflow-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..265e92f5d Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/card-Title-Overflow-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/checkbox-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/checkbox-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..568fa5631 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/checkbox-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/chevron-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/chevron-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..ee79a3408 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/chevron-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/datepicker-Daypicker-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Daypicker-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..889e5372c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Daypicker-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-Open-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-Open-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..47767f9f2 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-Open-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..fd70c5852 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Input-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/datepicker-Monthpicker-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Monthpicker-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..9110c0a9a Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Monthpicker-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/datepicker-Yearpicker-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Yearpicker-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..45bbf5c9a Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/datepicker-Yearpicker-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/definition-List-Defaults-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/definition-List-Defaults-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..f1db0312a Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/definition-List-Defaults-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/definition-List-Overrides-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/definition-List-Overrides-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..4b46f17d0 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/definition-List-Overrides-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Closed-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Closed-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..bfb4c70f2 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Closed-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Open-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Open-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..a05a631d1 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Button-Open-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Closed-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Closed-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..516c5a991 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Closed-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Open-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Open-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..d9e466831 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Context-Menu-Open-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/dropdown-Z-Index-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Z-Index-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..eaa31ddc2 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/dropdown-Z-Index-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/error-Images-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/error-Images-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..8be8d06b3 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/error-Images-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/error-Modal-Form-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/error-Modal-Form-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..915392c59 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/error-Modal-Form-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/file-Drop-Nolink-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/file-Drop-Nolink-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..94eff5ccf Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/file-Drop-Nolink-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/file-Drop-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/file-Drop-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..5c14c107e Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/file-Drop-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/filter-Button-Active-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/filter-Button-Active-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0cc551293 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/filter-Button-Active-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/filter-Button-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/filter-Button-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..aebea1987 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/filter-Button-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/filter-Inline-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/filter-Inline-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..381aeca44 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/filter-Inline-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/filter-Summary-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/filter-Summary-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..c52c63e1a Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/filter-Summary-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Asc-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Asc-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..a5db13d29 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Asc-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Desc-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Desc-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..3a126e1ea Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/grid-Sort-Desc-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/grid-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/grid-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..b37d310ab Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/grid-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/key-Info-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/key-Info-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..1438f57ed Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/key-Info-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/labels-All-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/labels-All-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..84d5cd742 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/labels-All-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-Checked-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-Checked-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..7cbfcabe4 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-Checked-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..b3de98f43 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/list-View-Checklist-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/list_secondary_actions-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/list_secondary_actions-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..7e4457aed Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/list_secondary_actions-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal-Content-Only-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal-Content-Only-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..214e466c9 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal-Content-Only-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal-Large-Mobile-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal-Large-Mobile-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..af6795b3c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal-Large-Mobile-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal-Large-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal-Large-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..cc5f8d588 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal-Large-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal-Small-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal-Small-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..f04d41df5 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal-Small-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..82edc1761 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal_large_size-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal_large_size-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..bf9956777 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal_large_size-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal_large_size_bounded-chrome-800x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal_large_size_bounded-chrome-800x800-dpr-1.png new file mode 100644 index 000000000..7e4a0aaee Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal_large_size_bounded-chrome-800x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal_medium_size-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal_medium_size-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..82edc1761 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal_medium_size-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/modal_small_size-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/modal_small_size-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..f37fd9f81 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/modal_small_size-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Item-Over-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Item-Over-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..9a2cfd49b Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Item-Over-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Open-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Open-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..1b8423898 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-Dropdown-Open-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-Child-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-Child-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0345f1a94 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-Child-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0345f1a94 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Active-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Over-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Over-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..bc315a479 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-Item-Over-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/navbar-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/navbar-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..19bdfd0d5 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/navbar-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..ef972ad91 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..43e6aaeea Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-All-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..0661814e3 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..d12fab3f8 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Image_title_subtitle-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noalert-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noalert-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..21b6338b2 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noalert-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nocontent-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nocontent-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..e424f7e24 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nocontent-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noimage-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noimage-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..a85ceb143 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Noimage-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nokeyinfo-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nokeyinfo-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..ffefa43b1 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nokeyinfo-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nostatus-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nostatus-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..d9e566b52 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nostatus-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nosubtitle-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nosubtitle-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..2116c3b0c Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/pagesummary-Nosubtitle-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/paging-First-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/paging-First-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..bf0fc97e3 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/paging-First-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/paging-Middle-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/paging-Middle-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..fdd5150f6 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/paging-Middle-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/radio-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/radio-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..719ec5018 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/radio-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/repeater-Collapsed-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/repeater-Collapsed-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..d87321911 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/repeater-Collapsed-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/repeater-Multiple-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/repeater-Multiple-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..e21de6f44 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/repeater-Multiple-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/repeater-Single-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/repeater-Single-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..62b93e2fe Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/repeater-Single-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/repeater-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/repeater-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..b124ebc62 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/repeater-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/search-Small-Applied-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Applied-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..b607f1df9 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Applied-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-Applied-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-Applied-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..642e0c32b Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-Applied-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..696ea1eed Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/search-Small-Dismissable-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/search-Small-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/search-Small-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..90d992669 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/search-Small-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/search-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/search-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..761497397 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/search-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/sort-Open-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/sort-Open-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..e6acfb703 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/sort-Open-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/sort-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/sort-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..f971ed5dc Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/sort-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-Long-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-Long-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..297262adc Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-Long-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..e604f228d Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-Dropdown-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..d43fc2ffe Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tabset-Collapsed-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tabset-Wizard-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tabset-Wizard-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..98fa49e04 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tabset-Wizard-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tabset-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tabset-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..4f2cabfcc Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tabset-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Modal-Expanded-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Modal-Expanded-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..1e1049561 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Modal-Expanded-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Normal-Expanded-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Normal-Expanded-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..dfa1eda25 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Normal-Expanded-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Not-Expanded-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Not-Expanded-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..5513f3fd1 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Not-Expanded-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Expanded-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Expanded-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..d49560ca4 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Expanded-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Not-Expanded-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Not-Expanded-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..4f61ca594 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Expand-Repeater-Not-Expanded-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Blank-Screenshot-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Blank-Screenshot-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..cde86dbc3 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Blank-Screenshot-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-No-Match-Screenshot-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-No-Match-Screenshot-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..94a945bad Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-No-Match-Screenshot-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Normal-Screenshot-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Normal-Screenshot-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..6bae6bc2b Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/text-Highlight-Normal-Screenshot-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tile-Small-chrome-480x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tile-Small-chrome-480x800-dpr-1.png new file mode 100644 index 000000000..e15ae34b6 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tile-Small-chrome-480x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/tile-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/tile-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..2307caf98 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/tile-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/toolbar-Section-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/toolbar-Section-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..2b0bd0619 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/toolbar-Section-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/toolbar-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/toolbar-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..e5658ce88 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/toolbar-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-Behind-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-Behind-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..8bab25ab2 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-Behind-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..9cbcb201e Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Absolute-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Non-Block-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Non-Block-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..6719016cd Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-Non-Block-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Component-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..7f7eebcfb Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Component-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-Non-Block-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-Non-Block-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..3aa5df527 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-Non-Block-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-chrome-1000x800-dpr-1.png b/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-chrome-1000x800-dpr-1.png new file mode 100644 index 000000000..826283816 Binary files /dev/null and b/skyux-spa-visual-tests/screenshots-baseline/wait-Full-Page-chrome-1000x800-dpr-1.png differ diff --git a/skyux-spa-visual-tests/skyuxconfig.json b/skyux-spa-visual-tests/skyuxconfig.json new file mode 100644 index 000000000..796aa9c1a --- /dev/null +++ b/skyux-spa-visual-tests/skyuxconfig.json @@ -0,0 +1,4 @@ +{ + "mode": "easy", + "compileMode": "aot" +} diff --git a/src/modules/action-button/fixtures/action-button.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/action-button/action-button-visual.component.html similarity index 100% rename from src/modules/action-button/fixtures/action-button.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/action-button/action-button-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/action-button/action-button-visual.component.ts b/skyux-spa-visual-tests/src/app/action-button/action-button-visual.component.ts new file mode 100644 index 000000000..d6ad2c65b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/action-button/action-button-visual.component.ts @@ -0,0 +1,14 @@ +import { Component} from '@angular/core'; + +@Component({ + selector: 'action-button-visual', + templateUrl: './action-button-visual.component.html' +}) +export class ActionButtonVisualComponent { + + public buttonIsClicked: boolean = false; + + public buttonClicked() { + this.buttonIsClicked = true; + } +} diff --git a/skyux-spa-visual-tests/src/app/action-button/action-button.visual-spec.ts b/skyux-spa-visual-tests/src/app/action-button/action-button.visual-spec.ts new file mode 100644 index 000000000..dce11e709 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/action-button/action-button.visual-spec.ts @@ -0,0 +1,31 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Action button', () => { + it('should match previous action button screenshot', () => { + return SkyVisualTest + .setupTest('action-button') + .then(() => { + SkyVisualTest.moveCursorOffScreen(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'action-button', + selector: '#screenshot-action-button', + checkAccessibility: true + }); + }); + + }); + + it('should match previous action button screenshot on small screens', () => { + return SkyVisualTest + .setupTest('action-button', 480) + .then(() => { + SkyVisualTest.moveCursorOffScreen(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'action-button-small', + selector: '#screenshot-action-button', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/action-button/index.html b/skyux-spa-visual-tests/src/app/action-button/index.html new file mode 100644 index 000000000..b9dc129bd --- /dev/null +++ b/skyux-spa-visual-tests/src/app/action-button/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/alert/fixtures/alert.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/alert/alert-visual.component.html similarity index 100% rename from src/modules/alert/fixtures/alert.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/alert/alert-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/alert/alert-visual.component.ts b/skyux-spa-visual-tests/src/app/alert/alert-visual.component.ts new file mode 100644 index 000000000..01f5bd367 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/alert/alert-visual.component.ts @@ -0,0 +1,9 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'alert-visual', + templateUrl: './alert-visual.component.html' +}) +export class AlertVisualComponent { + public alertCloseable = true; +} diff --git a/skyux-spa-visual-tests/src/app/alert/alert.visual-spec.ts b/skyux-spa-visual-tests/src/app/alert/alert.visual-spec.ts new file mode 100644 index 000000000..414f2d043 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/alert/alert.visual-spec.ts @@ -0,0 +1,17 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Alert', () => { + + it('should match previous alert screenshot', () => { + return SkyVisualTest + .setupTest('alert') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'alert', + selector: '#screenshot-alert', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/alert/index.html b/skyux-spa-visual-tests/src/app/alert/index.html new file mode 100644 index 000000000..32e3b007e --- /dev/null +++ b/skyux-spa-visual-tests/src/app/alert/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/app-extras.module.ts b/skyux-spa-visual-tests/src/app/app-extras.module.ts new file mode 100644 index 000000000..41dd9e7b8 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/app-extras.module.ts @@ -0,0 +1,24 @@ +import { NgModule } from '@angular/core'; + +import { ModalDemoComponent } from './modal/modal-demo.component'; +import { ModalLargeDemoComponent } from './modal/modal-large-demo.component'; +import { ModalFullPageDemoComponent } from './modal/modal-fullpage-demo.component'; +import { ModalContentDemoComponent } from './modal/modal-content-demo.component'; + +import { Tile1Component } from './tiles/tile1.component'; + +import { Tile2Component } from './tiles/tile2.component'; + +// Specify entry components, module-level providers, etc. here. +@NgModule({ + providers: [], + entryComponents: [ + ModalDemoComponent, + ModalLargeDemoComponent, + ModalFullPageDemoComponent, + ModalContentDemoComponent, + Tile1Component, + Tile2Component + ] +}) +export class AppExtrasModule { } diff --git a/src/modules/avatar/fixtures/avatar.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.html similarity index 80% rename from src/modules/avatar/fixtures/avatar.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.html index 38ed45058..b687f51c6 100644 --- a/src/modules/avatar/fixtures/avatar.component.visual-fixture.html +++ b/skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.html @@ -1,9 +1,9 @@
+ >
diff --git a/skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.ts b/skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.ts new file mode 100644 index 000000000..c053dca1b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/avatar/avatar-visual.component.ts @@ -0,0 +1,14 @@ +import { Component } from '@angular/core'; + +import { + SkyFileItem +} from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'avatar-visual', + templateUrl: './avatar-visual.component.html' +}) +export class AvatarVisualComponent { + public name = 'Robert C. Hernandez'; + +} diff --git a/skyux-spa-visual-tests/src/app/avatar/avatar.visual-spec.ts b/skyux-spa-visual-tests/src/app/avatar/avatar.visual-spec.ts new file mode 100644 index 000000000..027c6bb4f --- /dev/null +++ b/skyux-spa-visual-tests/src/app/avatar/avatar.visual-spec.ts @@ -0,0 +1,30 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Avatar', () => { + + it('should match previous screenshot when image is present', () => { + return SkyVisualTest + .setupTest('avatar') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'avatar-image', + selector: '#screenshot-avatar-img', + checkAccessibility: true + }); + }); + + }); + + it('should match previous screenshot when initials are present', () => { + return SkyVisualTest + .setupTest('avatar') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'avatar-initials', + selector: '#screenshot-avatar-initials', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/avatar/index.html b/skyux-spa-visual-tests/src/app/avatar/index.html new file mode 100644 index 000000000..e0238ba94 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/avatar/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/button/fixtures/button.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/button/button-visual.component.html similarity index 100% rename from src/modules/button/fixtures/button.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/button/button-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/button/button-visual.component.ts b/skyux-spa-visual-tests/src/app/button/button-visual.component.ts new file mode 100644 index 000000000..c556c16da --- /dev/null +++ b/skyux-spa-visual-tests/src/app/button/button-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'button-visual', + templateUrl: './button-visual.component.html' +}) +export class ButtonVisualComponent { } diff --git a/skyux-spa-visual-tests/src/app/button/button.visual-spec.ts b/skyux-spa-visual-tests/src/app/button/button.visual-spec.ts new file mode 100644 index 000000000..296a0e318 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/button/button.visual-spec.ts @@ -0,0 +1,42 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { browser, element, by } from 'protractor'; + +describe('Button', () => { + + it('should match previous button link screenshot on hover', () => { + return SkyVisualTest + .setupTest('button') + .then(() => { + browser.actions() + .mouseMove(element(by.css('#screenshot-button-link .sky-btn'))) + .perform(); + + return SkyVisualTest + .compareScreenshot({ + screenshotName: 'button-link-hover', + selector: '#screenshot-button-link', + checkAccessibility: true + }); + }); + + }); + + it('should match previous button link inline screenshot on hover', () => { + return SkyVisualTest + .setupTest('button') + .then(() => { + browser.actions() + .mouseMove(element(by.css('#screenshot-button-link-inline .sky-btn'))) + .perform(); + + return SkyVisualTest + .compareScreenshot({ + screenshotName: 'button-link-inline-hover', + selector: '#screenshot-button-link-inline', + checkAccessibility: true + }); + + }); + }); +}); diff --git a/skyux-spa-visual-tests/src/app/button/index.html b/skyux-spa-visual-tests/src/app/button/index.html new file mode 100644 index 000000000..59b01bd02 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/button/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/card/fixtures/card.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/card/card-visual.component.html similarity index 100% rename from src/modules/card/fixtures/card.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/card/card-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/card/card-visual.component.ts b/skyux-spa-visual-tests/src/app/card/card-visual.component.ts new file mode 100644 index 000000000..636cf0e2a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/card/card-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'card-visual', + templateUrl: './card-visual.component.html' +}) +export class CardVisualComponent { } diff --git a/skyux-spa-visual-tests/src/app/card/card.visual-spec.ts b/skyux-spa-visual-tests/src/app/card/card.visual-spec.ts new file mode 100644 index 000000000..275de1e8b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/card/card.visual-spec.ts @@ -0,0 +1,83 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by, browser } from 'protractor'; + +describe('Card', () => { + + it('should match previous screenshot when all components are present', () => { + return SkyVisualTest + .setupTest('card') + .then(() => { + return SkyVisualTest + .compareScreenshot({ + screenshotName: 'card-all', + selector: '#screenshot-card-all', + checkAccessibility: true + }); + }); + + + }); + + it('should match previous screenshot when no header is present', () => { + return SkyVisualTest + .setupTest('card') + .then(() => {; + return SkyVisualTest.compareScreenshot({ + screenshotName: 'card-noheader', + selector: '#screenshot-card-noheader', + checkAccessibility: true + }); + }); + }); + + it('should match previous screenshot when no actions are present', () => { + return SkyVisualTest.setupTest('card') + .then(() => {; + SkyVisualTest.scrollElementIntoView('#screenshot-card-noactions'); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'card-noactions', + selector: '#screenshot-card-noactions', + checkAccessibility: true + }); + }); + }); + + it('should match previous screenshot when selectable', () => { + return SkyVisualTest.setupTest('card') + .then(() => { + SkyVisualTest.scrollElementIntoView('#screenshot-card-selectable'); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'card-selectable', + selector: '#screenshot-card-selectable', + checkAccessibility: true + }); + }); + }); + + it('should match previous screenshot when the card is selected', () => { + return SkyVisualTest.setupTest('card') + .then(() => { + SkyVisualTest.scrollElementIntoView('#screenshot-card-selectable'); + element(by.css('#screenshot-card-selectable .sky-card-title')).click() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'card-selected', + selector: '#screenshot-card-selectable', + checkAccessibility: true + }); + }); + }); + + it('should match previous screenshot when the card has title overflow', () => { + return SkyVisualTest.setupTest('card') + .then(() => { + SkyVisualTest.scrollElementIntoView('#screenshot-card-overflow'); + SkyVisualTest.compareScreenshot({ + screenshotName: 'card-title-overflow', + selector: '#screenshot-card-overflow', + checkAccessibility: true + }); + }); + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/card/index.html b/skyux-spa-visual-tests/src/app/card/index.html new file mode 100644 index 000000000..29c250ec3 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/card/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/checkbox/fixtures/checkbox.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/checkbox/checkbox-visual.component.html similarity index 100% rename from src/modules/checkbox/fixtures/checkbox.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/checkbox/checkbox-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/checkbox/checkbox-visual.component.ts b/skyux-spa-visual-tests/src/app/checkbox/checkbox-visual.component.ts new file mode 100644 index 000000000..4b1c40c8a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/checkbox/checkbox-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'checkbox-visual', + templateUrl: './checkbox-visual.component.html' +}) +export class CheckboxVisualComponent { } diff --git a/skyux-spa-visual-tests/src/app/checkbox/checkbox.visual-spec.ts b/skyux-spa-visual-tests/src/app/checkbox/checkbox.visual-spec.ts new file mode 100644 index 000000000..2d5e53ef9 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/checkbox/checkbox.visual-spec.ts @@ -0,0 +1,16 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Checkbox', () => { + + it('should match previous checkbox screenshot', () => { + return SkyVisualTest.setupTest('checkbox') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'checkbox', + selector: '#screenshot-checkbox', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/checkbox/index.html b/skyux-spa-visual-tests/src/app/checkbox/index.html new file mode 100644 index 000000000..7377f8ebf --- /dev/null +++ b/skyux-spa-visual-tests/src/app/checkbox/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/chevron/fixtures/chevron.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/chevron/chevron-visual.component.html similarity index 100% rename from src/modules/chevron/fixtures/chevron.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/chevron/chevron-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/chevron/chevron-visual.component.ts b/skyux-spa-visual-tests/src/app/chevron/chevron-visual.component.ts new file mode 100644 index 000000000..8fdbce3fd --- /dev/null +++ b/skyux-spa-visual-tests/src/app/chevron/chevron-visual.component.ts @@ -0,0 +1,10 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'chevron-visual', + templateUrl: './chevron-visual.component.html' +}) +export class ChevronVisualComponent { + public directionUp = 'up'; + public directionDown = 'down'; +} diff --git a/skyux-spa-visual-tests/src/app/chevron/chevron.visual-spec.ts b/skyux-spa-visual-tests/src/app/chevron/chevron.visual-spec.ts new file mode 100644 index 000000000..6e63deab2 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/chevron/chevron.visual-spec.ts @@ -0,0 +1,16 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Chevron', () => { + + it('should match previous chevron screenshot', () => { + return SkyVisualTest.setupTest('chevron') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'chevron', + selector: '#screenshot-chevron', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/chevron/index.html b/skyux-spa-visual-tests/src/app/chevron/index.html new file mode 100644 index 000000000..f7504a343 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/chevron/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.html similarity index 90% rename from src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.html index a5d0f65b7..9007d44fb 100644 --- a/src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.html +++ b/skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.html @@ -1,8 +1,6 @@
diff --git a/skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.ts b/skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.ts new file mode 100644 index 000000000..f951dea18 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/datepicker/datepicker-visual.component.ts @@ -0,0 +1,9 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'datepicker-visual', + templateUrl: './datepicker-visual.component.html' +}) +export class DatepickerVisualComponent { + public selectedDate: Date = new Date('4/4/2017'); +} diff --git a/skyux-spa-visual-tests/src/app/datepicker/datepicker.visual-spec.ts b/skyux-spa-visual-tests/src/app/datepicker/datepicker.visual-spec.ts new file mode 100644 index 000000000..2ff19338b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/datepicker/datepicker.visual-spec.ts @@ -0,0 +1,70 @@ +import { SkyVisualTest} from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('Datepicker', () => { + + it('should match previous daypicker screenshot', () => { + return SkyVisualTest.setupTest('datepicker') + .then(() => { + SkyVisualTest.moveCursorOffScreen(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'datepicker-daypicker', + selector: '#screenshot-datepicker-calendar' + }); + }); + + }); + + it('should match previous monthpicker screenshot', () => { + return SkyVisualTest.setupTest('datepicker') + .then(() => { + element(by.css('.sky-datepicker-calendar-title')).click(); + SkyVisualTest.moveCursorOffScreen() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'datepicker-monthpicker', + selector: '#screenshot-datepicker-calendar' + }); + }); + + }); + + it('should match previous yearpicker screenshot', () => { + return SkyVisualTest.setupTest('datepicker') + .then(() => { + element(by.css('.sky-datepicker-calendar-title')).click(); + element(by.css('.sky-datepicker-calendar-title')).click(); + SkyVisualTest.moveCursorOffScreen() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'datepicker-yearpicker', + selector: '#screenshot-datepicker-calendar' + }); + }); + + }); + + it('should match previous datepicker input screenshot', () => { + return SkyVisualTest.setupTest('datepicker') + .then(() => { + SkyVisualTest.moveCursorOffScreen() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'datepicker-input', + selector: '#screenshot-datepicker' + }); + }); + + }); + + it('should match previous datepicker input screenshot when open', () => { + return SkyVisualTest.setupTest('datepicker') + .then(() => { + element(by.css('.sky-dropdown-button')).click(); + SkyVisualTest.moveCursorOffScreen() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'datepicker-input-open', + selector: '#screenshot-datepicker' + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/datepicker/index.html b/skyux-spa-visual-tests/src/app/datepicker/index.html new file mode 100644 index 000000000..83161c5d6 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/datepicker/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/definition-list/fixtures/definition-list.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/definition-list/definition-list-visual.component.html similarity index 100% rename from src/modules/definition-list/fixtures/definition-list.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/definition-list/definition-list-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/definition-list/definition-list-visual.component.ts b/skyux-spa-visual-tests/src/app/definition-list/definition-list-visual.component.ts new file mode 100644 index 000000000..f8bd105b9 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/definition-list/definition-list-visual.component.ts @@ -0,0 +1,35 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'definition-list-visual', + templateUrl: './definition-list-visual.component.html' +}) +export class DefinitionListVisualComponent { + public personalInfo: {label: string, value?: string}[] = [ + { + label: 'Job title', + value: 'Engineer' + }, + { + label: 'Hobby', + value: 'Volleyball' + }, + { + label: 'Experience' + } + ]; + + public systemInfo: {label: string, value?: string}[] = [ + { + label: 'Username', + value: 'user1' + }, + { + label: 'Role', + value: 'Admin' + }, + { + label: 'Last log-in time' + } + ]; +} diff --git a/skyux-spa-visual-tests/src/app/definition-list/definition-list.visual-spec.ts b/skyux-spa-visual-tests/src/app/definition-list/definition-list.visual-spec.ts new file mode 100644 index 000000000..b7db7e53c --- /dev/null +++ b/skyux-spa-visual-tests/src/app/definition-list/definition-list.visual-spec.ts @@ -0,0 +1,27 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Definition list', () => { + + it('should match definition list screenshot with default settings', () => { + return SkyVisualTest.setupTest('definition-list') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'definition-list-defaults', + selector: '#screenshot-definition-list-1' + }); + }); + + }); + + it('should match definition list screenshot with custom settings', () => { + return SkyVisualTest.setupTest('definition-list') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'definition-list-overrides', + selector: '#screenshot-definition-list-2' + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/definition-list/index.html b/skyux-spa-visual-tests/src/app/definition-list/index.html new file mode 100644 index 000000000..30ad6851c --- /dev/null +++ b/skyux-spa-visual-tests/src/app/definition-list/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/dropdown/fixtures/dropdown.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/dropdown/dropdown-visual.component.html similarity index 100% rename from src/modules/dropdown/fixtures/dropdown.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/dropdown/dropdown-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/dropdown/dropdown-visual.component.ts b/skyux-spa-visual-tests/src/app/dropdown/dropdown-visual.component.ts new file mode 100644 index 000000000..a41f38549 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/dropdown/dropdown-visual.component.ts @@ -0,0 +1,13 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'dropdown-visual', + templateUrl: './dropdown-visual.component.html' +}) +export class DropdownVisualComponent { + public dropdownOpen = false; + + public click() { + this.dropdownOpen = true; + } +} diff --git a/skyux-spa-visual-tests/src/app/dropdown/dropdown.visual-spec.ts b/skyux-spa-visual-tests/src/app/dropdown/dropdown.visual-spec.ts new file mode 100644 index 000000000..bb2965152 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/dropdown/dropdown.visual-spec.ts @@ -0,0 +1,64 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('Dropdown', () => { + + it('should match dropdown button screenshot when closed', () => { + return SkyVisualTest.setupTest('dropdown') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'dropdown-button-closed', + selector: '#screenshot-dropdown-button' + }); + }); + + }); + + it('should match dropdown button screenshot when open', () => { + return SkyVisualTest.setupTest('dropdown') + .then(() => { + element(by.css('#screenshot-dropdown-button .sky-dropdown-button')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'dropdown-button-open', + selector: '#screenshot-dropdown-button' + }); + }); + + }); + + it('should match dropdown context menu screenshot when closed', () => { + return SkyVisualTest.setupTest('dropdown') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'dropdown-context-menu-closed', + selector: '#screenshot-dropdown-context-menu' + }); + }); + + }); + + it('should match dropdown context menu screenshot when open', () => { + return SkyVisualTest.setupTest('dropdown') + .then(() => { + element(by.css('#screenshot-dropdown-context-menu .sky-dropdown-button')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'dropdown-context-menu-open', + selector: '#screenshot-dropdown-context-menu' + }); + }); + + }); + + it('should match dropdown screenshot when before a relative element', () => { + return SkyVisualTest.setupTest('dropdown') + .then(() => { + element(by.css('#screenshot-dropdown-z-index .sky-dropdown-button')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'dropdown-z-index', + selector: '#screenshot-dropdown-z-index' + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/dropdown/index.html b/skyux-spa-visual-tests/src/app/dropdown/index.html new file mode 100644 index 000000000..1a624f2eb --- /dev/null +++ b/skyux-spa-visual-tests/src/app/dropdown/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/error/fixtures/error.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/error/error-visual.component.html similarity index 98% rename from src/modules/error/fixtures/error.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/error/error-visual.component.html index fc4144c0f..923b3fce9 100644 --- a/src/modules/error/fixtures/error.component.visual-fixture.html +++ b/skyux-spa-visual-tests/src/app/error/error-visual.component.html @@ -1,7 +1,7 @@
- @@ -9,7 +9,7 @@ - @@ -17,7 +17,7 @@ - @@ -34,7 +34,7 @@ custom description - diff --git a/skyux-spa-visual-tests/src/app/error/error-visual.component.ts b/skyux-spa-visual-tests/src/app/error/error-visual.component.ts new file mode 100644 index 000000000..c2a74d485 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/error/error-visual.component.ts @@ -0,0 +1,23 @@ +import { Component } from '@angular/core'; + +import { + SkyErrorModalService +} from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'error-visual', + templateUrl: './error-visual.component.html' +}) +export class ErrorVisualComponent { + constructor(private modal: SkyErrorModalService) { } + + public openModal() { + const config: any = { + errorTitle: 'Some error title', + errorDescription: 'Description of error', + errorCloseText: 'Close button text' + }; + + this.modal.open(config); + } +} diff --git a/skyux-spa-visual-tests/src/app/error/error.visual-spec.ts b/skyux-spa-visual-tests/src/app/error/error.visual-spec.ts new file mode 100644 index 000000000..e60583615 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/error/error.visual-spec.ts @@ -0,0 +1,34 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('Error', () => { + + it('should match previous screenshot for broken type', () => { + return SkyVisualTest.setupTest('error') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'error-images', + selector: '#screenshot-error-img', + checkAccessibility: true + }); + }); + + }); + + it('should match previous error modal form screenshot', () => { + return SkyVisualTest.setupTest('error') + .then(() => { + element(by.css('.sky-test-error-modal')).click(); + SkyVisualTest.moveCursorOffScreen(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'error-modal-form', + selector: '.sky-modal', + checkAccessibility: true + }).then(() => { + element(by.css('.sky-error-modal-close .sky-btn-primary')).click(); + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/error/index.html b/skyux-spa-visual-tests/src/app/error/index.html new file mode 100644 index 000000000..0feb80734 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/error/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/fileattachments/fixtures/file-drop.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/fileattachments/fileattachments-visual.component.html similarity index 100% rename from src/modules/fileattachments/fixtures/file-drop.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/fileattachments/fileattachments-visual.component.html diff --git a/src/modules/fileattachments/fixtures/file-drop.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/fileattachments/fileattachments-visual.component.ts similarity index 76% rename from src/modules/fileattachments/fixtures/file-drop.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/fileattachments/fileattachments-visual.component.ts index 1c71c2820..1a43521da 100644 --- a/src/modules/fileattachments/fixtures/file-drop.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/fileattachments/fileattachments-visual.component.ts @@ -1,20 +1,17 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; +import { Component } from '@angular/core'; import { SkyFileAttachmentsModule, SkyFileItem, SkyFileLink, SkyFileDropChange -} from '../'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; +} from '@blackbaud/skyux/dist/core'; @Component({ - selector: 'sky-demo-app', - templateUrl: './file-drop.component.visual-fixture.html' + selector: 'fileattachments-visual', + templateUrl: './fileattachments-visual.component.html' }) -class AppComponent { +export class FileAttachmentsVisualComponent { public filesToUpload: Array; public allItems: Array; @@ -56,6 +53,8 @@ class AppComponent { public validateFile(file: SkyFileItem) { if (file.file.name.indexOf('a') === 0) { return 'You may not upload a file that begins with the letter "a."'; + } else { + return ''; } } @@ -75,19 +74,3 @@ class AppComponent { } } } - -@NgModule({ - imports: [ - BrowserModule, - SkyFileAttachmentsModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/fileattachments/fileattachments.visual-spec.ts b/skyux-spa-visual-tests/src/app/fileattachments/fileattachments.visual-spec.ts new file mode 100644 index 000000000..4e527271d --- /dev/null +++ b/skyux-spa-visual-tests/src/app/fileattachments/fileattachments.visual-spec.ts @@ -0,0 +1,29 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('File drop', () => { + + it('should match the file drop control', () => { + return SkyVisualTest.setupTest('fileattachments') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'file-drop', + selector: '#screenshot-file-drop' + }); + }); + + }); + + it('should match the file drop control when no links allowed', () => { + return SkyVisualTest.setupTest('fileattachments') + .then(() => { + element(by.css('.sky-test-allow-links')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'file-drop-nolink', + selector: '#screenshot-file-drop' + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/fileattachments/index.html b/skyux-spa-visual-tests/src/app/fileattachments/index.html new file mode 100644 index 000000000..eb3e2c04a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/fileattachments/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/filter/fixtures/filter.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/filter/filter-visual.component.html similarity index 100% rename from src/modules/filter/fixtures/filter.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/filter/filter-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/filter/filter-visual.component.ts b/skyux-spa-visual-tests/src/app/filter/filter-visual.component.ts new file mode 100644 index 000000000..db342e1d0 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/filter/filter-visual.component.ts @@ -0,0 +1,20 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'filter-visual', + templateUrl: './filter-visual.component.html' +}) +export class FilterVisualComponent { + public filtersActive: boolean = false; + + public appliedFilters: Array = [ + { + label: 'hide orange', + dismissible: false + }, + { + label: 'berry fruit type', + dismissible: true + } + ]; +} diff --git a/skyux-spa-visual-tests/src/app/filter/filter.visual-spec.ts b/skyux-spa-visual-tests/src/app/filter/filter.visual-spec.ts new file mode 100644 index 000000000..1671b1689 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/filter/filter.visual-spec.ts @@ -0,0 +1,55 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('Filter', () => { + + it('should match previous screenshot for filter button', () => { + return SkyVisualTest.setupTest('filter') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'filter-button', + selector: '#screenshot-filter-button', + checkAccessibility: true + }); + }); + + }); + + it('should match previous screenshot for active filter button', () => { + return SkyVisualTest.setupTest('filter') + .then(() => { + element(by.css('.sky-btn-default')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'filter-button-active', + selector: '#screenshot-filter-button', + checkAccessibility: true + }); + }); + + }); + + it('should match previous screenshot for filter summary', () => { + return SkyVisualTest.setupTest('filter') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'filter-summary', + selector: '#screenshot-filter-summary', + checkAccessibility: true + }); + }); + + }); + + it('should match previous screenshot for filter inline', () => { + return SkyVisualTest.setupTest('filter') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'filter-inline', + selector: '#screenshot-filter-inline', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/filter/index.html b/skyux-spa-visual-tests/src/app/filter/index.html new file mode 100644 index 000000000..5f548dbf4 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/filter/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/grid/fixtures/grid.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/grid/grid-visual.component.html similarity index 100% rename from src/modules/grid/fixtures/grid.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/grid/grid-visual.component.html diff --git a/src/modules/grid/fixtures/grid.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/grid/grid-visual.component.ts similarity index 56% rename from src/modules/grid/fixtures/grid.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/grid/grid-visual.component.ts index 89f3f4201..1c0196c25 100644 --- a/src/modules/grid/fixtures/grid.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/grid/grid-visual.component.ts @@ -1,23 +1,14 @@ import { Component, - NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { - SkyGridModule -} from '../grid.module'; - -import { ListItemModel } from '../../../../src/modules/list/state/items/item.model'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; +import { ListItemModel } from '@blackbaud/skyux/dist/core'; @Component({ - selector: 'sky-demo-app', - templateUrl: './grid.component.visual-fixture.html' + selector: 'grid-visual', + templateUrl: './grid-visual.component.html' }) -export class AppComponent { +export class GridVisualComponent { public items = [ new ListItemModel('1', { column1: '1', column2: 'Apple', @@ -36,19 +27,3 @@ export class AppComponent { column3: 'gg' }) ]; } - -@NgModule({ - imports: [ - BrowserModule, - SkyGridModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/grid/grid.visual-spec.ts b/skyux-spa-visual-tests/src/app/grid/grid.visual-spec.ts new file mode 100644 index 000000000..372835cac --- /dev/null +++ b/skyux-spa-visual-tests/src/app/grid/grid.visual-spec.ts @@ -0,0 +1,44 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; +import { element, by } from 'protractor'; + +describe('grid component', () => { + + it('should display grid', () => { + return SkyVisualTest.setupTest('grid') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'grid', + selector: '#screenshot-grid', + checkAccessibility: true + }); + }); + + }); + + it('should display grid with descending sort indication', () => { + return SkyVisualTest.setupTest('grid') + .then(() => { + element(by.css('th')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'grid-sort-desc', + selector: '#screenshot-grid', + checkAccessibility: true + }); + }); + + }); + + it('should display grid with ascending sort indication', () => { + return SkyVisualTest.setupTest('grid') + .then(() => { + element(by.css('th')).click(); + element(by.css('th')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'grid-sort-asc', + selector: '#screenshot-grid', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/grid/index.html b/skyux-spa-visual-tests/src/app/grid/index.html new file mode 100644 index 000000000..358d88521 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/grid/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/home.component.html b/skyux-spa-visual-tests/src/app/home.component.html new file mode 100644 index 000000000..1c45b223a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/home.component.html @@ -0,0 +1,12 @@ +

SKY UX Visual Tests

+ +

This is the home page for SKY UX visual tests.

+ + + {{test}} + + + diff --git a/skyux-spa-visual-tests/src/app/home.component.ts b/skyux-spa-visual-tests/src/app/home.component.ts new file mode 100644 index 000000000..7d94c9f89 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/home.component.ts @@ -0,0 +1,44 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'my-home', + templateUrl: './home.component.html' +}) +export class HomeComponent { + + public tests: Array = [ + 'action-button', + 'alert', + 'avatar', + 'button', + 'card', + 'checkbox', + 'chevron', + 'datepicker', + 'definition-list', + 'dropdown', + 'error', + 'fileattachments', + 'filter', + 'grid', + 'key-info', + 'label', + 'list-secondary-actions', + 'list-view-checklist', + 'modal', + 'navbar', + 'page-summary', + 'paging', + 'radio', + 'repeater', + 'search', + 'sort', + 'tabs', + 'text-expand', + 'text-expand-repeater', + 'text-highlight', + 'tiles', + 'toolbar', + 'wait' + ]; +} diff --git a/skyux-spa-visual-tests/src/app/index.html b/skyux-spa-visual-tests/src/app/index.html new file mode 100644 index 000000000..2608a425f --- /dev/null +++ b/skyux-spa-visual-tests/src/app/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/key-info/index.html b/skyux-spa-visual-tests/src/app/key-info/index.html new file mode 100644 index 000000000..32e764a23 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/key-info/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/key-info/fixtures/key-info.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/key-info/key-info-visual.component.html similarity index 100% rename from src/modules/key-info/fixtures/key-info.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/key-info/key-info-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/key-info/key-info-visual.component.ts b/skyux-spa-visual-tests/src/app/key-info/key-info-visual.component.ts new file mode 100644 index 000000000..15f4321ce --- /dev/null +++ b/skyux-spa-visual-tests/src/app/key-info/key-info-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'key-info-visual', + templateUrl: './key-info-visual.component.html' +}) +export class KeyInfoVisualComponent {} diff --git a/skyux-spa-visual-tests/src/app/key-info/key-info.visual-spec.ts b/skyux-spa-visual-tests/src/app/key-info/key-info.visual-spec.ts new file mode 100644 index 000000000..77c31f5f5 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/key-info/key-info.visual-spec.ts @@ -0,0 +1,17 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('KeyInfo', () => { + + it('should match previous key-info screenshot', () => { + return SkyVisualTest.setupTest('key-info') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'key-info', + selector: '#screenshot-key-info', + checkAccessibility: true + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/label/index.html b/skyux-spa-visual-tests/src/app/label/index.html new file mode 100644 index 000000000..927b044e5 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/label/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/label/fixtures/label.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/label/label-visual.component.html similarity index 100% rename from src/modules/label/fixtures/label.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/label/label-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/label/label-visual.component.ts b/skyux-spa-visual-tests/src/app/label/label-visual.component.ts new file mode 100644 index 000000000..d5460766e --- /dev/null +++ b/skyux-spa-visual-tests/src/app/label/label-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'label-visual', + templateUrl: './label-visual.component.html' +}) +export class LabelVisualComponent { } diff --git a/skyux-spa-visual-tests/src/app/label/label.visual-spec.ts b/skyux-spa-visual-tests/src/app/label/label.visual-spec.ts new file mode 100644 index 000000000..78c50d7b5 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/label/label.visual-spec.ts @@ -0,0 +1,16 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Label', () => { + + it('should match previous label screenshot', () => { + return SkyVisualTest.setupTest('label') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'labels-all', + selector: '#screenshot-label', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/list-secondary-actions/index.html b/skyux-spa-visual-tests/src/app/list-secondary-actions/index.html new file mode 100644 index 000000000..814679076 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/list-secondary-actions/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/list-secondary-actions/fixtures/list-secondary-actions.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions-visual.component.html similarity index 100% rename from src/modules/list-secondary-actions/fixtures/list-secondary-actions.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions-visual.component.html diff --git a/src/modules/list-view-checklist/fixtures/list-view-checklist.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions-visual.component.ts similarity index 55% rename from src/modules/list-view-checklist/fixtures/list-view-checklist.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions-visual.component.ts index c6392bd71..de69b9c3f 100644 --- a/src/modules/list-view-checklist/fixtures/list-view-checklist.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions-visual.component.ts @@ -1,17 +1,13 @@ -import { Component, NgModule} from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; +import { Component } from '@angular/core'; import { Observable } from 'rxjs/Observable'; - -import { SkyListModule } from '../../list'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; +import 'rxjs/add/observable/of' @Component({ - selector: 'sky-demo-app', - templateUrl: './list-view-checklist.component.visual-fixture.html' + selector: 'list-secondary-actions-visual', + templateUrl: './list-secondary-actions-visual.component.html' }) -export class AppComponent { +export class ListSecondaryActionsVisualComponent { public data: Observable> = Observable.of([ { id: '1', column1: 101, column2: 'Apple', column3: 'Anne eats apples'}, @@ -23,19 +19,3 @@ export class AppComponent { { id: '7', column1: 707, column2: 'Strawberry', column3: 'Sally eats strawberries' } ]); } - -@NgModule({ - imports: [ - BrowserModule, - SkyListModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions.visual-spec.ts b/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions.visual-spec.ts new file mode 100644 index 000000000..ec459be18 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/list-secondary-actions/list-secondary-actions.visual-spec.ts @@ -0,0 +1,18 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; +import { element, by } from 'protractor'; + +describe('list-secondary-actions component', () => { + + it('should display toolbar with secondary actions', () => { + return SkyVisualTest.setupTest('list-secondary-actions') + .then(() => { + element(by.css('.sky-list-secondary-actions .sky-dropdown-button')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'list_secondary_actions', + selector: '#screenshot-list-secondary-actions', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/list-view-checklist/index.html b/skyux-spa-visual-tests/src/app/list-view-checklist/index.html new file mode 100644 index 000000000..665713840 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/list-view-checklist/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/list-view-checklist/fixtures/list-view-checklist.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist-visual.component.html similarity index 100% rename from src/modules/list-view-checklist/fixtures/list-view-checklist.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist-visual.component.html diff --git a/src/modules/list-secondary-actions/fixtures/list-secondary-actions.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist-visual.component.ts similarity index 55% rename from src/modules/list-secondary-actions/fixtures/list-secondary-actions.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist-visual.component.ts index 975c67cb6..71ba4b90f 100644 --- a/src/modules/list-secondary-actions/fixtures/list-secondary-actions.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist-visual.component.ts @@ -1,17 +1,12 @@ -import { Component, NgModule} from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; +import { Component } from '@angular/core'; import { Observable } from 'rxjs/Observable'; -import { SkyListModule } from '../../list'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - @Component({ - selector: 'sky-demo-app', - templateUrl: './list-secondary-actions.component.visual-fixture.html' + selector: 'list-view-checklist-visual', + templateUrl: './list-view-checklist-visual.component.html' }) -export class AppComponent { +export class ListViewChecklistVisualComponent { public data: Observable> = Observable.of([ { id: '1', column1: 101, column2: 'Apple', column3: 'Anne eats apples'}, @@ -23,19 +18,3 @@ export class AppComponent { { id: '7', column1: 707, column2: 'Strawberry', column3: 'Sally eats strawberries' } ]); } - -@NgModule({ - imports: [ - BrowserModule, - SkyListModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist.visual-spec.ts b/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist.visual-spec.ts new file mode 100644 index 000000000..748771bea --- /dev/null +++ b/skyux-spa-visual-tests/src/app/list-view-checklist/list-view-checklist.visual-spec.ts @@ -0,0 +1,29 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('list-view-checklist component', () => { + + it('should display checklist view', () => { + return SkyVisualTest.setupTest('list-view-checklist') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'list-view-checklist', + selector: '#screenshot-list-view-checklist' + }); + }); + + }); + + it('should display checklist view with checked', () => { + return SkyVisualTest.setupTest('list-view-checklist') + .then(() => { + element(by.css('sky-checkbox')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'list-view-checklist-checked', + selector: '#screenshot-list-view-checklist' + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/modal/index.html b/skyux-spa-visual-tests/src/app/modal/index.html new file mode 100644 index 000000000..ffc57d0fc --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.html b/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.html new file mode 100644 index 000000000..878743b2b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.html @@ -0,0 +1,6 @@ + + + Content + + + diff --git a/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.ts b/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.ts new file mode 100644 index 000000000..bd7586451 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-content-demo.component.ts @@ -0,0 +1,12 @@ +import { Component } from '@angular/core'; + +import { SkyModalInstance } from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'sky-test-cmp-modal-content', + templateUrl: './modal-content-demo.component.html' +}) +export class ModalContentDemoComponent { + + constructor(public instance: SkyModalInstance) {} +} diff --git a/skyux-spa-visual-tests/src/app/modal/modal-demo.component.html b/skyux-spa-visual-tests/src/app/modal/modal-demo.component.html new file mode 100644 index 000000000..efd8f8abd --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-demo.component.html @@ -0,0 +1,11 @@ + + + {{title}} + + + Content A + + + Footer + + diff --git a/skyux-spa-visual-tests/src/app/modal/modal-demo.component.ts b/skyux-spa-visual-tests/src/app/modal/modal-demo.component.ts new file mode 100644 index 000000000..d71075ad8 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-demo.component.ts @@ -0,0 +1,18 @@ +import { Component, OnInit } from '@angular/core'; + +import { SkyModalService } from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'sky-test-cmp-modal', + templateUrl: './modal-demo.component.html', + providers: [SkyModalService] +}) +export class ModalDemoComponent implements OnInit { + public title = 'Hello world'; + + constructor(private modalService: SkyModalService) { } + + public ngOnInit() { + console.log('init happened'); + } +} diff --git a/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.html b/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.html new file mode 100644 index 000000000..7af543e4c --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.html @@ -0,0 +1,11 @@ + + + {{title}} + + + Content for Full Screen + + + Footer + + diff --git a/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.ts b/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.ts new file mode 100644 index 000000000..e9cf31940 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-fullpage-demo.component.ts @@ -0,0 +1,18 @@ +import { Component, OnInit } from '@angular/core'; + +import { SkyModalService } from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'sky-test-cmp-modal-fullpage', + templateUrl: './modal-fullpage-demo.component.html', + providers: [SkyModalService] +}) +export class ModalFullPageDemoComponent implements OnInit { + public title = 'Hello world'; + + constructor(private modalService: SkyModalService) { } + + public ngOnInit() { + console.log('init happened'); + } +} diff --git a/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.html b/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.html new file mode 100644 index 000000000..efd8f8abd --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.html @@ -0,0 +1,11 @@ + + + {{title}} + + + Content A + + + Footer + + diff --git a/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.ts b/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.ts new file mode 100644 index 000000000..dd8126ee0 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/modal/modal-large-demo.component.ts @@ -0,0 +1,18 @@ +import { Component, OnInit } from '@angular/core'; + +import { SkyModalService } from '@blackbaud/skyux/dist/core'; + +@Component({ + selector: 'sky-test-cmp-modal-large', + templateUrl: './modal-large-demo.component.html', + providers: [SkyModalService] +}) +export class ModalLargeDemoComponent implements OnInit { + public title = 'Hello world'; + + constructor(private modalService: SkyModalService) { } + + public ngOnInit() { + console.log('init happened'); + } +} diff --git a/src/modules/modal/fixtures/modal.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/modal/modal-visual.component.html similarity index 99% rename from src/modules/modal/fixtures/modal.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/modal/modal-visual.component.html index fbc9e9503..022f4ab93 100644 --- a/src/modules/modal/fixtures/modal.component.visual-fixture.html +++ b/skyux-spa-visual-tests/src/app/modal/modal-visual.component.html @@ -3,7 +3,7 @@ type="button" class="sky-btn sky-btn-primary" (click)="openModal()" - > +> Open modal +
- -
- - - Title 1 - Content 1 - - - Title 2 - Content 2 - - -
diff --git a/skyux-spa-visual-tests/src/app/repeater/repeater-visual.component.ts b/skyux-spa-visual-tests/src/app/repeater/repeater-visual.component.ts new file mode 100644 index 000000000..aa38addbc --- /dev/null +++ b/skyux-spa-visual-tests/src/app/repeater/repeater-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'repeater-visual', + templateUrl: './repeater-visual.component.html' +}) +export class RepeaterVisualComponent { } diff --git a/skyux-spa-visual-tests/src/app/repeater/repeater.visual-spec.ts b/skyux-spa-visual-tests/src/app/repeater/repeater.visual-spec.ts new file mode 100644 index 000000000..f2689456d --- /dev/null +++ b/skyux-spa-visual-tests/src/app/repeater/repeater.visual-spec.ts @@ -0,0 +1,54 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Repeater', () => { + + it('should match previous repeater screenshot', () => { + return SkyVisualTest + .setupTest('repeater') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'repeater', + selector: '#screenshot-repeater', + checkAccessibility: true + }); + }); + + }); + + it('should match previous repeater screenshot when all are collapsed', () => { + return SkyVisualTest.setupTest('repeater') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'repeater-collapsed', + selector: '#screenshot-repeater-collapsed', + checkAccessibility: true + }); + }); + + }); + + it('should match previous repeater screenshot in single mode', () => { + return SkyVisualTest.setupTest('repeater') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'repeater-single', + selector: '#screenshot-repeater-single', + checkAccessibility: true + }); + }); + + }); + + it('should match previous repeater screenshot in multiple mode', () => { + return SkyVisualTest.setupTest('repeater') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'repeater-multiple', + selector: '#screenshot-repeater-multiple', + checkAccessibility: true + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/search/index.html b/skyux-spa-visual-tests/src/app/search/index.html new file mode 100644 index 000000000..15b5d45e9 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/search/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/search/fixtures/search.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/search/search-visual.component.html similarity index 100% rename from src/modules/search/fixtures/search.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/search/search-visual.component.html diff --git a/src/modules/search/fixtures/search.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/search/search-visual.component.ts similarity index 66% rename from src/modules/search/fixtures/search.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/search/search-visual.component.ts index 39333f642..89a58d5b3 100644 --- a/src/modules/search/fixtures/search.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/search/search-visual.component.ts @@ -1,28 +1,16 @@ import { - Component, - NgModule + Component } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { - SkySearchModule -} from '../search.module'; - -import { - SkyToolbarModule -} from '../../toolbar'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; @Component({ - selector: 'sky-demo-app', - templateUrl: './search.component.visual-fixture.html' + selector: 'search-visual', + templateUrl: './search-visual.component.html' }) -export class AppComponent { +export class SearchVisualComponent { public displayedItems: any; public searchText: string; - private items = [ + private items: Array = [ { title: 'Call Robert Hernandez', note: 'Robert recently gave a very generous gift. We should call to thank him.' @@ -55,11 +43,13 @@ export class AppComponent { if (searchText) { filteredItems = this.items.filter(function (item) { let property: any; - for (property in item) { + for (property in item as any) { if (item.hasOwnProperty(property) && (property === 'title' || property === 'note')) { + /* tslint:disable */ if (item[property].indexOf(searchText) > -1) { return true; } + /* tslint:enable */ } } return false; @@ -68,20 +58,3 @@ export class AppComponent { this.displayedItems = filteredItems; } } - -@NgModule({ - imports: [ - BrowserModule, - SkySearchModule, - SkyToolbarModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/search/search.visual-spec.ts b/skyux-spa-visual-tests/src/app/search/search.visual-spec.ts new file mode 100644 index 000000000..85d76a32a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/search/search.visual-spec.ts @@ -0,0 +1,89 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { browser, element, by } from 'protractor'; + +describe('search component', () => { + + it('should match the baseline search screenshot', () => { + return SkyVisualTest.setupTest('search') + .then(() => { + browser.sleep(2000); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'search', + selector: '#screenshot-search-full', + checkAccessibility: true + }); + }); + + }); + + it('should match the baseline search screenshot on small screens', () => { + return SkyVisualTest.setupTest('search', 480) + .then(() => { + browser.sleep(1000); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'search-small', + selector: '#screenshot-search-full', + checkAccessibility: true + }); + }); + + }); + + it('should match the baseline search screenshot on small screens when dismissable input is shown', + () => { + return SkyVisualTest.setupTest('search', 480) + .then(() => { + browser.sleep(1000); + element(by.css('.sky-search-btn-open')).click(); + browser.sleep(1000) + return SkyVisualTest.compareScreenshot({ + screenshotName: 'search-small-dismissable', + selector: '#screenshot-search-full', + checkAccessibility: true + }); + }); + + }); + + it('should match the baseline search screenshot on small screens when search is applied', + () => { + return SkyVisualTest.setupTest('search', 480) + .then(() => { + browser.sleep(1000); + element(by.css('.sky-search-btn-open')).click(); + browser.sleep(1000); + element(by.css('.sky-search-input')).sendKeys('Value'); + element(by.css('.sky-search-btn-apply')).click(); + browser.sleep(1000) + return SkyVisualTest.compareScreenshot({ + screenshotName: 'search-small-dismissable-applied', + selector: '#screenshot-search-full', + checkAccessibility: true + }); + }); + + }); + + it('should match the baseline screenshot on small screens when search is applied and dismissed', + () => { + return SkyVisualTest.setupTest('search', 480) + .then(() => { + browser.sleep(1000); + element(by.css('.sky-search-btn-open')).click(); + browser.sleep(1000); + element(by.css('.sky-search-input')).sendKeys('Value'); + element(by.css('.sky-search-btn-apply')).click(); + browser.sleep(1000) + element(by.css('.sky-search-btn-dismiss')).click(); + browser.sleep(1000) + return SkyVisualTest.compareScreenshot({ + screenshotName: 'search-small-applied', + selector: '#screenshot-search-full', + checkAccessibility: true + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/sort/index.html b/skyux-spa-visual-tests/src/app/sort/index.html new file mode 100644 index 000000000..2458b53c3 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/sort/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/sort/fixtures/sort.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/sort/sort-visual.component.html similarity index 100% rename from src/modules/sort/fixtures/sort.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/sort/sort-visual.component.html diff --git a/src/modules/sort/fixtures/sort.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/sort/sort-visual.component.ts similarity index 59% rename from src/modules/sort/fixtures/sort.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/sort/sort-visual.component.ts index 24f9f48b5..a60bfb6d6 100644 --- a/src/modules/sort/fixtures/sort.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/sort/sort-visual.component.ts @@ -1,24 +1,12 @@ import { - Component, - NgModule + Component } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { - SkySortModule -} from '../sort.module'; - -import { - SkyToolbarModule -} from '../../toolbar'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; @Component({ - selector: 'sky-demo-app', - templateUrl: './sort.component.visual-fixture.html' + selector: 'sort-visual', + templateUrl: './sort-visual.component.html' }) -export class AppComponent { +export class SortVisualComponent { public initialState = 3; public sortOptions = [ { @@ -64,21 +52,5 @@ export class AppComponent { public sortItems(item: any) { this.sortedItem = item; } -} - -@NgModule({ - imports: [ - BrowserModule, - SkySortModule, - SkyToolbarModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } -Bootstrapper.bootstrapModule(AppModule); +} diff --git a/skyux-spa-visual-tests/src/app/sort/sort.visual-spec.ts b/skyux-spa-visual-tests/src/app/sort/sort.visual-spec.ts new file mode 100644 index 000000000..2c9d59dab --- /dev/null +++ b/skyux-spa-visual-tests/src/app/sort/sort.visual-spec.ts @@ -0,0 +1,32 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('Sort component', () => { + + it('should match the baseline sort screenshot', () => { + return SkyVisualTest.setupTest('sort') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'sort', + selector: '#screenshot-sort-full', + checkAccessibility: true + }); + }); + + }); + + it('should match the baseline sort screenshot when dropdown is open', () => { + return SkyVisualTest.setupTest('sort') + .then(() => { + element(by.css('.sky-btn-default')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'sort-open', + selector: '#screenshot-sort-full', + checkAccessibility: true + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/tabs/index.html b/skyux-spa-visual-tests/src/app/tabs/index.html new file mode 100644 index 000000000..c2dea66e6 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tabs/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/tabs/fixtures/tabset.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/tabs/tabs-visual.component.html similarity index 100% rename from src/modules/tabs/fixtures/tabset.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/tabs/tabs-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/tabs/tabs-visual.component.ts b/skyux-spa-visual-tests/src/app/tabs/tabs-visual.component.ts new file mode 100644 index 000000000..41062db95 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tabs/tabs-visual.component.ts @@ -0,0 +1,33 @@ +import { ChangeDetectionStrategy, Component} from '@angular/core'; + +@Component({ + selector: 'tabs-visual', + templateUrl: './tabs-visual.component.html', + changeDetection: ChangeDetectionStrategy.OnPush +}) +export class TabsVisualComponent { + + public showWizard = false; + + public requiredValue1: string; + + public requiredValue2: boolean; + + public newTabClick() { } + + public openTabClick() { } + + public closeTab() { } + + public get step2Disabled(): boolean { + return !this.requiredValue1; + } + + public get step3Disabled(): boolean { + return this.step2Disabled || !this.requiredValue2; + } + + public validateStep1() { + return true; + } +} diff --git a/skyux-spa-visual-tests/src/app/tabs/tabs.visual-spec.ts b/skyux-spa-visual-tests/src/app/tabs/tabs.visual-spec.ts new file mode 100644 index 000000000..7ddc2f54e --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tabs/tabs.visual-spec.ts @@ -0,0 +1,65 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; +import { element, by } from 'protractor'; + +describe('TabSet', () => { + + it('should match previous tabset screenshot', () => { + return SkyVisualTest.setupTest('tabs') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tabset', + selector: '#screenshot-tabset' + }); + }); + + }); + + it('should match the tabset screenshot with wizard styling', () => { + return SkyVisualTest.setupTest('tabs') + .then(() => { + element(by.css('.sky-test-show-wizard')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tabset-wizard', + selector: '#screenshot-tabset' + }); + }); + + }); + + it('should match previous mobile tabset screenshot', () => { + return SkyVisualTest.setupTest('tabs', 480) + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tabset-collapsed', + selector: '#screenshot-tabset' + }); + }); + + }); + + it('should match previous mobile dropdown tabset screenshot', () => { + return SkyVisualTest.setupTest('tabs', 480) + .then(() => { + element(by.css('#screenshot-tabset button.sky-dropdown-button-type-tab')).click(); + SkyVisualTest.moveCursorOffScreen(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tabset-collapsed-dropdown', + selector: '#screenshot-tabset' + }); + }); + + }); + + it('should match previous mobile dropdown tabset screenshot with long tab', () => { + return SkyVisualTest.setupTest('tabs', 480) + .then(() => { + SkyVisualTest.moveCursorOffScreen() + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tabset-collapsed-dropdown-long', + selector: '#screenshot-tabset-long' + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/text-expand-repeater/index.html b/skyux-spa-visual-tests/src/app/text-expand-repeater/index.html new file mode 100644 index 000000000..e56fb737e --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-expand-repeater/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/text-expand-repeater/fixtures/text-expand-repeater.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater-visual.component.html similarity index 100% rename from src/modules/text-expand-repeater/fixtures/text-expand-repeater.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater-visual.component.ts b/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater-visual.component.ts new file mode 100644 index 000000000..3a3f2b6a8 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater-visual.component.ts @@ -0,0 +1,7 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'text-expand-repeater-visual', + templateUrl: './text-expand-repeater-visual.component.html' +}) +export class TextExpandRepeaterVisualComponent {} diff --git a/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater.visual-spec.ts b/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater.visual-spec.ts new file mode 100644 index 000000000..e0c3e0d6a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-expand-repeater/text-expand-repeater.visual-spec.ts @@ -0,0 +1,31 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; +import { element, by } from 'protractor'; + +describe('TextExpandRepeater', () => { + + it('should match previous text expand repeater when not expanded', () => { + return SkyVisualTest.setupTest('text-expand-repeater') + .then(() => { + return SkyVisualTest.compareScreenshot({ + checkAccessibility: true, + screenshotName: 'text-expand-repeater-not-expanded', + selector: '#text-expand-repeater' + }); + }); + + }); + + it('should match the previous text expand repeater when expanded', () => { + return SkyVisualTest.setupTest('text-expand-repeater') + .then(() => { + element(by.css('.sky-text-expand-repeater-see-more')).click(); + return SkyVisualTest.compareScreenshot({ + checkAccessibility: true, + screenshotName: 'text-expand-repeater-expanded', + selector: '#text-expand-repeater' + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/text-expand/index.html b/skyux-spa-visual-tests/src/app/text-expand/index.html new file mode 100644 index 000000000..2a5a6f340 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-expand/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/text-expand/fixtures/text-expand.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/text-expand/text-expand-visual.component.html similarity index 100% rename from src/modules/text-expand/fixtures/text-expand.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/text-expand/text-expand-visual.component.html diff --git a/src/modules/text-expand/fixtures/text-expand.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/text-expand/text-expand-visual.component.ts similarity index 72% rename from src/modules/text-expand/fixtures/text-expand.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/text-expand/text-expand-visual.component.ts index 4b69436b5..1d4e9dda2 100644 --- a/src/modules/text-expand/fixtures/text-expand.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/text-expand/text-expand-visual.component.ts @@ -1,34 +1,13 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyTextExpandModule } from '../text-expand.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; +import { Component } from '@angular/core'; @Component({ - selector: 'sky-demo-app', - templateUrl: './text-expand.component.visual-fixture.html' + selector: 'text-expand-visual', + templateUrl: './text-expand-visual.component.html' }) -class AppComponent { +export class TextExpandVisualComponent { // tslint:disable-next-line public veryShortText: string = 'Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec qu'; public shortText: string = 'Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec.'; // tslint:disable-next-line public longText: string = 'Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. In enim justo, rhoncus ut, imperdiet a, venenatis vitae, justo. Nullam dictum felis eu pede mollis pretium. Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. Quisque rutrum. Aenean imperdiet. Etiam ultricies' } - -@NgModule({ - imports: [ - BrowserModule, - SkyTextExpandModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/text-expand/text-expand.visual-spec.ts b/skyux-spa-visual-tests/src/app/text-expand/text-expand.visual-spec.ts new file mode 100644 index 000000000..2bb82073b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-expand/text-expand.visual-spec.ts @@ -0,0 +1,44 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('TextExpand', () => { + + it('should match previous text expands when not expanded', () => { + return SkyVisualTest.setupTest('text-expand') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-expand-not-expanded', + selector: '#text-expands' + }); + }); + + }); + + it('should match the previous normal text expand when expanded', () => { + return SkyVisualTest.setupTest('text-expand') + .then(() => { + element(by.css('#normal-text-expand .sky-text-expand-see-more')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-expand-normal-expanded', + selector: '#normal-text-expand' + }); + }); + + }); + + it('should match previous modal text expand when expanded', () => { + return SkyVisualTest.setupTest('text-expand') + .then(() => { + element(by.css('#modal-text-expand .sky-text-expand-see-more')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-expand-modal-expanded', + selector: '.sky-modal' + }).then(() => { + element(by.css('.sky-modal .sky-modal-btn-close')).click(); + }); + }); + + }); + +}); diff --git a/skyux-spa-visual-tests/src/app/text-highlight/index.html b/skyux-spa-visual-tests/src/app/text-highlight/index.html new file mode 100644 index 000000000..8ae1903fe --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-highlight/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.html b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.html new file mode 100644 index 000000000..4a71f76cd --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.html @@ -0,0 +1,9 @@ +
+
The text that you enter is highlighted here.
+
+
+
The text that you enter is highlighted here.
+
+
+
The text that you enter is highlighted here.
+
\ No newline at end of file diff --git a/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.ts b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.ts new file mode 100644 index 000000000..4bb8f109a --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight-visual.component.ts @@ -0,0 +1,12 @@ +import { ChangeDetectionStrategy, Component} from '@angular/core'; + +@Component({ + selector: 'text-highlight-visual', + templateUrl: './text-highlight-visual.component.html', + changeDetection: ChangeDetectionStrategy.OnPush +}) +export class TextHighlightVisualComponent { + public normalSearchTerm: string = 'enter'; + public blankSearchTerm: string = ''; + public notMatchedSearchTerm: string = 'xnotmatched'; +} diff --git a/skyux-spa-visual-tests/src/app/text-highlight/text-highlight.visual-spec.ts b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight.visual-spec.ts new file mode 100644 index 000000000..66115073b --- /dev/null +++ b/skyux-spa-visual-tests/src/app/text-highlight/text-highlight.visual-spec.ts @@ -0,0 +1,35 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; +import { element, by } from 'protractor'; + +describe('TextHighlight', () => { + + it('should match previous text highlight screenshot', () => { + return SkyVisualTest.setupTest('text-highlight') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-highlight-normal-screenshot', + selector: '#text-highlight-normal' + }); + }); + }); + + it('should match previous text highlight screenshot when term is blank', () => { + return SkyVisualTest.setupTest('text-highlight') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-highlight-blank-screenshot', + selector: '#text-highlight-blank' + }); + }); + }); + + it('should match previous text highlight screenshot when term is not matched', () => { + return SkyVisualTest.setupTest('text-highlight') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'text-highlight-no-match-screenshot', + selector: '#text-highlight-no-match' + }); + }); + }); +}); diff --git a/skyux-spa-visual-tests/src/app/tiles/index.html b/skyux-spa-visual-tests/src/app/tiles/index.html new file mode 100644 index 000000000..5147d0b8c --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tiles/index.html @@ -0,0 +1 @@ + diff --git a/skyux-spa-visual-tests/src/app/tiles/tile1.component.ts b/skyux-spa-visual-tests/src/app/tiles/tile1.component.ts new file mode 100644 index 000000000..cdf280abe --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tiles/tile1.component.ts @@ -0,0 +1,35 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'sky-tile-1', + template: ` + + + Tile 1 + + + $123.4m + + + Section 1 + Section 2 + + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf +
+
+
+
+ ` +}) +export class Tile1Component { + constructor() { + console.log('Created tile 1 component'); + } + + public tileSettingsClick() { + alert('tile settings clicked'); + } +} diff --git a/skyux-spa-visual-tests/src/app/tiles/tile2.component.ts b/skyux-spa-visual-tests/src/app/tiles/tile2.component.ts new file mode 100644 index 000000000..87821fcd8 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tiles/tile2.component.ts @@ -0,0 +1,27 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'sky-tile-2', + template: ` + + + Tile 2 + + + Section 1 + Section 2 + + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + asdf asdf asdf sadf sadf asdf asdf sadf asdf asdf asdf asdf asdf asdf + + + + ` +}) +export class Tile2Component { + constructor() { + console.log('Created tile 2 component'); + } +} diff --git a/src/modules/tiles/fixtures/tile.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/tiles/tiles-visual.component.html similarity index 100% rename from src/modules/tiles/fixtures/tile.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/tiles/tiles-visual.component.html diff --git a/src/modules/tiles/fixtures/tile.component.visual-fixture.ts b/skyux-spa-visual-tests/src/app/tiles/tiles-visual.component.ts similarity index 62% rename from src/modules/tiles/fixtures/tile.component.visual-fixture.ts rename to skyux-spa-visual-tests/src/app/tiles/tiles-visual.component.ts index af349b0c5..828013f80 100644 --- a/src/modules/tiles/fixtures/tile.component.visual-fixture.ts +++ b/skyux-spa-visual-tests/src/app/tiles/tiles-visual.component.ts @@ -1,17 +1,15 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; +import { Component } from '@angular/core'; -import { SkyTilesModule, SkyTileDashboardConfig } from '../'; +import { SkyTileDashboardConfig } from '@blackbaud/skyux/dist/core'; -import { Bootstrapper } from '../../../../visual/bootstrapper'; import { Tile1Component } from './tile1.component'; import { Tile2Component } from './tile2.component'; @Component({ - selector: 'sky-demo-app', - templateUrl: './tile.component.visual-fixture.html' + selector: 'tiles-visual', + templateUrl: './tiles-visual.component.html' }) -export class AppComponent { +export class TilesVisualComponent { public dashboardConfig: SkyTileDashboardConfig; public stringify(obj: any) { @@ -65,25 +63,3 @@ export class AppComponent { }; } } - -@NgModule({ - imports: [ - BrowserModule, - SkyTilesModule - ], - declarations: [ - AppComponent, - Tile1Component, - Tile2Component - ], - bootstrap: [ - AppComponent - ], - entryComponents: [ - Tile1Component, - Tile2Component - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/skyux-spa-visual-tests/src/app/tiles/tiles.visual-spec.ts b/skyux-spa-visual-tests/src/app/tiles/tiles.visual-spec.ts new file mode 100644 index 000000000..d5d2cd34f --- /dev/null +++ b/skyux-spa-visual-tests/src/app/tiles/tiles.visual-spec.ts @@ -0,0 +1,28 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Tile', () => { + + it('should match previous tile screenshot', () => { + return SkyVisualTest.setupTest('tiles') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tile', + selector: '#screenshot-tiles', + checkAccessibility: true + }); + }); + + }); + + it('should match previous tile screenshot on small screens', () => { + return SkyVisualTest.setupTest('tiles', 480) + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'tile-small', + selector: '#screenshot-tiles', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/app/toolbar/index.html b/skyux-spa-visual-tests/src/app/toolbar/index.html new file mode 100644 index 000000000..c8ce7350e --- /dev/null +++ b/skyux-spa-visual-tests/src/app/toolbar/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/toolbar/fixtures/toolbar.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/toolbar/toolbar-visual.component.html similarity index 100% rename from src/modules/toolbar/fixtures/toolbar.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/toolbar/toolbar-visual.component.html diff --git a/skyux-spa-visual-tests/src/app/toolbar/toolbar-visual.component.ts b/skyux-spa-visual-tests/src/app/toolbar/toolbar-visual.component.ts new file mode 100644 index 000000000..ba0b44be0 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/toolbar/toolbar-visual.component.ts @@ -0,0 +1,8 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'toolbar-visual', + templateUrl: './toolbar-visual.component.html' +}) +export class ToolbarVisualComponent { +} diff --git a/skyux-spa-visual-tests/src/app/toolbar/toolbar.visual-spec.ts b/skyux-spa-visual-tests/src/app/toolbar/toolbar.visual-spec.ts new file mode 100644 index 000000000..a4f58806d --- /dev/null +++ b/skyux-spa-visual-tests/src/app/toolbar/toolbar.visual-spec.ts @@ -0,0 +1,29 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +describe('Toolbar', () => { + + it('should match previous toolbar screenshot', () => { + return SkyVisualTest.setupTest('toolbar') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'toolbar', + selector: '#screenshot-toolbar', + checkAccessibility: true + }); + }); + + }); + + it('should match previous toolbar screenshot with sections', () => { + return SkyVisualTest.setupTest('toolbar') + .then(() => { + return SkyVisualTest.compareScreenshot({ + screenshotName: 'toolbar-section', + selector: '#screenshot-toolbar-sectioned', + checkAccessibility: true + }); + }); + + }); +}); + diff --git a/skyux-spa-visual-tests/src/app/wait/index.html b/skyux-spa-visual-tests/src/app/wait/index.html new file mode 100644 index 000000000..e482112c9 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/wait/index.html @@ -0,0 +1 @@ + diff --git a/src/modules/wait/fixtures/wait.component.visual-fixture.html b/skyux-spa-visual-tests/src/app/wait/wait-visual.component.html similarity index 98% rename from src/modules/wait/fixtures/wait.component.visual-fixture.html rename to skyux-spa-visual-tests/src/app/wait/wait-visual.component.html index 3648a1310..b2c47f8a9 100644 --- a/src/modules/wait/fixtures/wait.component.visual-fixture.html +++ b/skyux-spa-visual-tests/src/app/wait/wait-visual.component.html @@ -31,7 +31,7 @@
-

+

A large area that can be waited with the sky-wait directive.

diff --git a/src/modules/wait/fixtures/wait.component.visual-fixture.scss b/skyux-spa-visual-tests/src/app/wait/wait-visual.component.scss similarity index 100% rename from src/modules/wait/fixtures/wait.component.visual-fixture.scss rename to skyux-spa-visual-tests/src/app/wait/wait-visual.component.scss diff --git a/skyux-spa-visual-tests/src/app/wait/wait-visual.component.ts b/skyux-spa-visual-tests/src/app/wait/wait-visual.component.ts new file mode 100644 index 000000000..fda71caf4 --- /dev/null +++ b/skyux-spa-visual-tests/src/app/wait/wait-visual.component.ts @@ -0,0 +1,12 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'wait-visual', + templateUrl: './wait-visual.component.html', + styleUrls: ['./wait-visual.component.scss'] +}) +export class WaitVisualComponent { + public isWaiting: boolean; + public isFullPage: boolean; + public isNonBlocking: boolean; +} diff --git a/skyux-spa-visual-tests/src/app/wait/wait.visual-spec.ts b/skyux-spa-visual-tests/src/app/wait/wait.visual-spec.ts new file mode 100644 index 000000000..1b578793f --- /dev/null +++ b/skyux-spa-visual-tests/src/app/wait/wait.visual-spec.ts @@ -0,0 +1,90 @@ +import { SkyVisualTest } from '../../../config/utils/visual-test-commands'; + +import { element, by } from 'protractor'; + +describe('wait component', () => { + + it('should display wait on parent', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-wait')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-component', + selector: '#screenshot-wait', + checkAccessibility: true + }); + }); + + }); + + it('should display wait on parent to block absolute item', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-wait')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-component-absolute', + selector: '#screenshot-wait-absolute', + checkAccessibility: true + }); + }); + + }); + + it('should display wait behind parent with modal z-index', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-wait')).click(); + SkyVisualTest.scrollElementIntoView('#screenshot-wait-behind') + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-component-absolute-behind', + selector: '#screenshot-wait-behind', + checkAccessibility: true + }); + }); + + }); + + + it('should display nonblocking wait on parent', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-non-blocking')).click(); + element(by.css('.sky-test-wait')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-component-non-block', + selector: '#screenshot-wait', + checkAccessibility: true + }); + }); + + }); + + it('should display wait on full page', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-full-page')).click(); + element(by.css('.sky-test-wait')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-full-page', + selector: 'body', + checkAccessibility: true + }); + }); + + }); + + it('should display non blocking wait on full page', () => { + return SkyVisualTest.setupTest('wait') + .then(() => { + element(by.css('.sky-test-full-page')).click(); + element(by.css('.sky-test-non-blocking')).click(); + element(by.css('.sky-test-wait')).click(); + return SkyVisualTest.compareScreenshot({ + screenshotName: 'wait-full-page-non-block', + selector: 'body', + checkAccessibility: true + }); + }); + + }); +}); diff --git a/skyux-spa-visual-tests/src/assets/avatar.png b/skyux-spa-visual-tests/src/assets/avatar.png new file mode 100644 index 000000000..57f0f42ee Binary files /dev/null and b/skyux-spa-visual-tests/src/assets/avatar.png differ diff --git a/skyux-spa-visual-tests/tsconfig.json b/skyux-spa-visual-tests/tsconfig.json new file mode 100644 index 000000000..9177985a1 --- /dev/null +++ b/skyux-spa-visual-tests/tsconfig.json @@ -0,0 +1,29 @@ +{ + "extends": "./node_modules/@blackbaud/skyux-builder/tsconfig", + "compilerOptions": { + "target": "es5", + "module": "commonjs", + "moduleResolution": "node", + "emitDecoratorMetadata": true, + "experimentalDecorators": true, + "lib": [ + "dom", + "es6" + ], + "types": [ + "jasmine", + "node" + ], + "baseUrl": ".", + "paths": { + "sky-pages-spa/src/*": ["./src/*"], + "sky-pages-internal/*": ["./node_modules/@blackbaud/skyux-builder/*"], + "@blackbaud/skyux/dist/core": ["./node_modules/@blackbaud/skyux/dist/core"] + } + }, + "exclude": [ + "node_modules" + ], + "compileOnSave": false, + "buildOnSave": false +} diff --git a/skyux-spa-visual-tests/tslint.json b/skyux-spa-visual-tests/tslint.json new file mode 100644 index 000000000..141cb48e9 --- /dev/null +++ b/skyux-spa-visual-tests/tslint.json @@ -0,0 +1,3 @@ +{ + "extends": "@blackbaud/skyux-builder/tslint" +} diff --git a/skyuxconfig.json b/skyuxconfig.json index 029531475..593d15a56 100644 --- a/skyuxconfig.json +++ b/skyuxconfig.json @@ -5,7 +5,6 @@ "cssPath": "src/scss/sky.scss", "compileMode": "aot", "plugins": [ - "@blackbaud/skyux-builder-plugin-stache-code-block", - "@blackbaud/skyux-builder-plugin-stache-include" + "@blackbaud/skyux-builder-plugin-stache" ] } diff --git a/src/app/app-extras.module.ts b/src/app/app-extras.module.ts index fefad4798..72838aab3 100644 --- a/src/app/app-extras.module.ts +++ b/src/app/app-extras.module.ts @@ -1,8 +1,7 @@ import { NgModule } from '@angular/core'; -import { StacheModule, StacheConfigService } from'@blackbaud/stache'; +import { StacheModule } from'@blackbaud/stache'; -import { SkyAppConfig } from '@blackbaud/skyux-builder/runtime'; import { SkyDemoTitleService } from './shared/title.service'; import { SkyFilterDemoModalComponent } from './components/filter/filter-demo-modal.component'; import { SkyListFiltersModalDemoComponent } @@ -34,11 +33,7 @@ require('style-loader!./styles.scss'); StacheModule ], providers: [ - SkyDemoTitleService, - { - provide: StacheConfigService, - useExisting: SkyAppConfig - } + SkyDemoTitleService ] }) export class AppExtrasModule { } diff --git a/src/app/components/demo-components.service.ts b/src/app/components/demo-components.service.ts index 9c9f4d18b..bd37c2dc5 100644 --- a/src/app/components/demo-components.service.ts +++ b/src/app/components/demo-components.service.ts @@ -316,6 +316,28 @@ export class SkyDemoComponentsService { ]; } }, + { + name: 'Highlight', + icon: 'paint-brush', + summary: `The highlight component highlights text within DOM elements.`, + url: '/components/text-highlight', + getCodeFiles: function () { + return [ + { + name: 'text-highlight-demo.component.html', + // tslint:disable-next-line + fileContents: require('!!raw-loader!./text-highlight/text-highlight-demo.component.html') + }, + { + name: 'text-highlight-demo.component.ts', + // tslint:disable-next-line + fileContents: require('!!raw-loader!./text-highlight/text-highlight-demo.component.ts'), + componentName: 'SkyTextHighlightDemoComponent', + bootstrapSelector: 'sky-text-highlight-demo' + } + ]; + } + }, { name: 'Key info', icon: 'key', diff --git a/src/app/components/dropdown/dropdown-demo.component.html b/src/app/components/dropdown/dropdown-demo.component.html index 780da69f0..787230112 100644 --- a/src/app/components/dropdown/dropdown-demo.component.html +++ b/src/app/components/dropdown/dropdown-demo.component.html @@ -44,7 +44,7 @@
  • Select primary style:
    - + Show dropdown @@ -60,7 +60,7 @@
  • Context menu with primary style:
    - + - + - + diff --git a/src/app/components/shared/demo-page-plunker-service.ts b/src/app/components/shared/demo-page-plunker-service.ts index 99bda9430..23788c25b 100644 --- a/src/app/components/shared/demo-page-plunker-service.ts +++ b/src/app/components/shared/demo-page-plunker-service.ts @@ -61,18 +61,18 @@ export class SkyDemoPagePlunkerService { 'app': '.', - '@angular/core': 'npm:@angular/core@2.4.5/bundles/core.umd.js', - '@angular/common': 'npm:@angular/common@2.4.5/bundles/common.umd.js', - '@angular/compiler': 'npm:@angular/compiler@2.4.5/bundles/compiler.umd.js', - '@angular/platform-browser': 'npm:@angular/platform-browser@2.4.5/bundles/platform-browser.umd.js', - '@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic@2.4.5/bundles/platform-browser-dynamic.umd.js', - '@angular/http': 'npm:@angular/http@2.4.5/bundles/http.umd.js', - '@angular/router': 'npm:@angular/router@3.4.5/bundles/router.umd.js', - '@angular/forms': 'npm:@angular/forms@2.4.5/bundles/forms.umd.js', - - 'rxjs': 'npm:rxjs@5.1.0', - 'typescript': 'npm:typescript@2.0.2/lib/typescript.js', - '@blackbaud/skyux/dist/core': 'npm:@blackbaud/skyux@2.0.0-beta.33/dist/bundles/core.umd.js', + '@angular/core': 'npm:@angular/core@4.2.5/bundles/core.umd.js', + '@angular/common': 'npm:@angular/common@4.2.5/bundles/common.umd.js', + '@angular/compiler': 'npm:@angular/compiler@4.2.5/bundles/compiler.umd.js', + '@angular/platform-browser': 'npm:@angular/platform-browser@4.2.5/bundles/platform-browser.umd.js', + '@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic@4.2.5/bundles/platform-browser-dynamic.umd.js', + '@angular/http': 'npm:@angular/http@4.2.5/bundles/http.umd.js', + '@angular/router': 'npm:@angular/router@4.2.5/bundles/router.umd.js', + '@angular/forms': 'npm:@angular/forms@4.2.5/bundles/forms.umd.js', + + 'rxjs': 'npm:rxjs@5.4.0', + 'typescript': 'npm:typescript@2.3.2/lib/typescript.js', + '@blackbaud/skyux/dist/core': 'npm:@blackbaud/skyux/dist/bundles/core.umd.js', 'moment': 'npm:moment/moment.js', diff --git a/src/app/components/text-highlight/index.html b/src/app/components/text-highlight/index.html new file mode 100644 index 000000000..8b1de8cb8 --- /dev/null +++ b/src/app/components/text-highlight/index.html @@ -0,0 +1,18 @@ + + + The highlight directive allows you to highlight text within DOM elements. When you set the skyHighlight attribute to the text you want to highlight, it highlights all matching text within the element. + + + + + Specifies the text to highlight. + + + + + + + + diff --git a/src/app/components/text-highlight/text-highlight-demo.component.html b/src/app/components/text-highlight/text-highlight-demo.component.html new file mode 100644 index 000000000..ecf16102c --- /dev/null +++ b/src/app/components/text-highlight/text-highlight-demo.component.html @@ -0,0 +1,23 @@ +
    + +
    + +
    + +
    + + Display additional content + +
    + +
    The text that you enter is highlighted here. +
    + This additional content is highlighted too! +
    +
    diff --git a/src/app/components/text-highlight/text-highlight-demo.component.ts b/src/app/components/text-highlight/text-highlight-demo.component.ts new file mode 100644 index 000000000..eb318d3ed --- /dev/null +++ b/src/app/components/text-highlight/text-highlight-demo.component.ts @@ -0,0 +1,10 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'sky-text-highlight-demo', + templateUrl: './text-highlight-demo.component.html' +}) +export class SkyTextHighlightDemoComponent { + public searchTerm: string; + public showAdditionalContent: boolean = false; +} diff --git a/src/app/design/color/index.html b/src/app/design/color/index.html index 03e7c5055..558ff1155 100644 --- a/src/app/design/color/index.html +++ b/src/app/design/color/index.html @@ -1,16 +1,16 @@ - As a general rule, SKY UX uses color to convey meaning and not as pure decoration. You should rarely apply colors directly to elements because components incorporate colors as necessary. If a need for color arises outside of a component, you likely need to create a component for that scenario. - +

    Background, border, and text colors are derived from base colors through tinting and shading.

    - For text, ensure that the contrast between the text color and the background color is at least 4.5:1 to meet Web Content Accessibility Guidelines 2.0 level AA. + For text, ensure that the contrast between the text color and the background color is at least 4.5:1 to meet Web Content Accessibility Guidelines 2.0 level AA.
    @@ -149,5 +149,5 @@
  • - + diff --git a/src/app/design/typography/index.html b/src/app/design/typography/index.html index 0f62a09df..712813ceb 100644 --- a/src/app/design/typography/index.html +++ b/src/app/design/typography/index.html @@ -1,6 +1,6 @@ - @@ -10,8 +10,8 @@

    SKY UX defines CSS classes for general use in addition to base body copy.

    - Styling values are for reference only, and you should not apply them directly. Instead, components should apply styling through the use of classes. - + Styling values are for reference only, and you should not apply them directly. Instead, components should apply styling through the use of classes. +

    Page heading

    @@ -191,7 +191,7 @@

    Section heading

    - +
    Warning
    @@ -211,7 +211,7 @@

    Section heading

    - +
    Danger
    @@ -231,5 +231,5 @@

    Section heading

    - - \ No newline at end of file + + diff --git a/src/core.ts b/src/core.ts index c592aefb6..f6ba7f8af 100644 --- a/src/core.ts +++ b/src/core.ts @@ -40,6 +40,7 @@ import { SkySortModule } from './modules/sort'; import { SkyTabsModule } from './modules/tabs'; import { SkyTextExpandModule } from './modules/text-expand'; import { SkyTextExpandRepeaterModule } from './modules/text-expand-repeater'; +import { SkyTextHighlightModule } from './modules/text-highlight'; import { SkyToolbarModule } from './modules/toolbar'; import { SkyTilesModule } from './modules/tiles'; import { SkyTimepickerModule } from './modules/timepicker'; @@ -84,6 +85,7 @@ import { SkyWaitModule } from './modules/wait'; SkyTabsModule, SkyTextExpandModule, SkyTextExpandRepeaterModule, + SkyTextHighlightModule, SkyTilesModule, SkyTimepickerModule, SkyToolbarModule, @@ -101,7 +103,7 @@ export { SkyNumericModule, SkyNumericPipe, SkyNumericService -} from './modules/numeric' +} from './modules/numeric'; export { SkyAvatarComponent, SkyAvatarInnerComponent, @@ -158,14 +160,15 @@ export { export { SkyEmailValidationDirective, SkyEmailValidationModule -} from './modules/email-validation' +} from './modules/email-validation'; export { SkyErrorComponent, SkyErrorDescriptionComponent, SkyErrorImageComponent, SkyErrorModule, SkyErrorTitleComponent, - SkyErrorModalService + SkyErrorModalService, + ErrorModalConfig } from './modules/error'; export { SkyFileAttachmentsModule, @@ -356,7 +359,11 @@ export { SkyTextExpandRepeaterModule } from './modules/text-expand-repeater'; export { - SkyTileComponent, + SkyTextHighlightDirective, + SkyTextHighlightModule +} from './modules/text-highlight'; +export { + SkyTileDashboardService, SkyTileContentModule, SkyTileContentSectionComponent, SkyTileDashboardColumnComponent, @@ -368,9 +375,9 @@ export { SkyTileDashboardConfigLayoutTile, SkyTileDashboardConfigTile, SkyTileDashboardModule, - SkyTileDashboardService, SkyTileModule, - SkyTilesModule + SkyTilesModule, + SkyTileComponent } from './modules/tiles'; export { SkyTimepickerComponent, diff --git a/src/modules/action-button/action-button.component.visual-spec.js b/src/modules/action-button/action-button.component.visual-spec.js deleted file mode 100644 index bf85bdb28..000000000 --- a/src/modules/action-button/action-button.component.visual-spec.js +++ /dev/null @@ -1,23 +0,0 @@ -describe('Action button', function () { - 'use strict'; - - it('should match previous action button screenshot', function () { - return browser - .setupTest('/action-button.html') - .compareScreenshot({ - screenshotName: 'action_button', - selector: '#screenshot-action-button', - checkAccessibility: true - }); - }); - - it('should match previous action-button screenshot on small screens', function () { - return browser - .setupTest('/action-button.html', 480) - .compareScreenshot({ - screenshotName: 'action_button_small', - selector: '#screenshot-action-button', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/action-button/fixtures/action-button.component.visual-fixture.ts b/src/modules/action-button/fixtures/action-button.component.visual-fixture.ts deleted file mode 100644 index 8601ca094..000000000 --- a/src/modules/action-button/fixtures/action-button.component.visual-fixture.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyActionButtonModule } from '../action-button.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './action-button.component.visual-fixture.html' -}) -export class AppComponent { - - public buttonIsClicked: boolean = false; - - public buttonClicked() { - this.buttonIsClicked = true; - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyActionButtonModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/alert/alert.component.visual-spec.js b/src/modules/alert/alert.component.visual-spec.js deleted file mode 100644 index 0874c6649..000000000 --- a/src/modules/alert/alert.component.visual-spec.js +++ /dev/null @@ -1,13 +0,0 @@ -describe('Alert', function () { - 'use strict'; - - it('should match previous alert screenshot', function () { - return browser - .setupTest('/alert.html') - .compareScreenshot({ - screenshotName: 'alert', - selector: '#screenshot-alert', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/alert/fixtures/alert.component.visual-fixture.ts b/src/modules/alert/fixtures/alert.component.visual-fixture.ts deleted file mode 100644 index 83e9c8275..000000000 --- a/src/modules/alert/fixtures/alert.component.visual-fixture.ts +++ /dev/null @@ -1,30 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyAlertModule } from '../alert.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './alert.component.visual-fixture.html' -}) -class AppComponent { - public alertCloseable = true; -} - -@NgModule({ - imports: [ - BrowserModule, - SkyAlertModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/avatar/avatar.component.ts b/src/modules/avatar/avatar.component.ts index e246a9fde..73d844a4e 100644 --- a/src/modules/avatar/avatar.component.ts +++ b/src/modules/avatar/avatar.component.ts @@ -62,6 +62,7 @@ export class SkyAvatarComponent { constructor(private errorService: SkyErrorModalService) {} public photoDrop(result: SkyFileDropChange) { + /* sanity check */ /* istanbul ignore else */ if (result.files && result.files.length > 0) { this.avatarChanged.emit(result.files[0]); diff --git a/src/modules/avatar/avatar.component.visual-spec.js b/src/modules/avatar/avatar.component.visual-spec.js deleted file mode 100644 index dd8fb633f..000000000 --- a/src/modules/avatar/avatar.component.visual-spec.js +++ /dev/null @@ -1,23 +0,0 @@ -describe('Avatar', function () { - 'use strict'; - - it('should match previous screenshot when image is present', function () { - return browser - .setupTest('/avatar.html') - .compareScreenshot({ - screenshotName: 'avatar-image', - selector: '#screenshot-avatar-img', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when initials are present', function () { - return browser - .setupTest('/avatar.html') - .compareScreenshot({ - screenshotName: 'avatar-initials', - selector: '#screenshot-avatar-initials', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/avatar/fixtures/avatar.component.visual-fixture.ts b/src/modules/avatar/fixtures/avatar.component.visual-fixture.ts deleted file mode 100644 index fa08eef9e..000000000 --- a/src/modules/avatar/fixtures/avatar.component.visual-fixture.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyAvatarModule, SkyAvatarSrc } from '../'; - -import { SkyFileItem } from '../../fileattachments'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './avatar.component.visual-fixture.html' -}) -class AppComponent { - public name = 'Robert C. Hernandez'; - - public src: SkyAvatarSrc = require('./avatar.png'); - - public avatarUpdated(file: SkyFileItem) { - if (file !== undefined) { - this.src = file.file; - } - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyAvatarModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/button/button.component.visual-spec.js b/src/modules/button/button.component.visual-spec.js deleted file mode 100644 index f46e15fd9..000000000 --- a/src/modules/button/button.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('Button', function () { - 'use strict'; - - it('should match previous button link screenshot on hover', function () { - return browser - .setupTest('/button.html') - .moveToObject('#screenshot-button-link .sky-btn') - .compareScreenshot({ - screenshotName: 'button_link_hover', - selector: '#screenshot-button-link', - checkAccessibility: true - }); - }); - - it('should match previous button link inline screenshot on hover', function () { - return browser - .setupTest('/button.html') - .moveToObject('#screenshot-button-link-inline .sky-btn') - .compareScreenshot({ - screenshotName: 'button_link_inline_hover', - selector: '#screenshot-button-link-inline', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/button/fixtures/button.component.visual-fixture.ts b/src/modules/button/fixtures/button.component.visual-fixture.ts deleted file mode 100644 index e590fa420..000000000 --- a/src/modules/button/fixtures/button.component.visual-fixture.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './button.component.visual-fixture.html' -}) -class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/card/card.component.visual-spec.js b/src/modules/card/card.component.visual-spec.js deleted file mode 100644 index 8aa4d01e0..000000000 --- a/src/modules/card/card.component.visual-spec.js +++ /dev/null @@ -1,65 +0,0 @@ -describe('Card', function () { - 'use strict'; - - it('should match previous screenshot when all components are present', function () { - return browser - .setupTest('/card.html') - .compareScreenshot({ - screenshotName: 'card-all', - selector: '#screenshot-card-all', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when no header is present', function () { - return browser - .setupTest('/card.html') - .compareScreenshot({ - screenshotName: 'card-noheader', - selector: '#screenshot-card-noheader', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when no actions are present', function () { - return browser - .setupTest('/card.html') - .compareScreenshot({ - screenshotName: 'card-noactions', - selector: '#screenshot-card-noactions', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when selectable', function () { - return browser - .setupTest('/card.html') - .compareScreenshot({ - screenshotName: 'card-selectable', - selector: '#screenshot-card-selectable', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when the card is selected', function () { - return browser - .setupTest('/card.html') - .click('.sky-card-title') - .compareScreenshot({ - screenshotName: 'card-selected', - selector: '#screenshot-card-selectable', - checkAccessibility: true - }); - }); - - it('should match previous screenshot when the card has title overflow', function () { - return browser - .setupTest('/card.html') - .compareScreenshot({ - screenshotName: 'card_title_overflow', - selector: '#screenshot-card-overflow', - checkAccessibility: true - }); - }); - -}); diff --git a/src/modules/card/fixtures/card.component.visual-fixture.ts b/src/modules/card/fixtures/card.component.visual-fixture.ts deleted file mode 100644 index d67789790..000000000 --- a/src/modules/card/fixtures/card.component.visual-fixture.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyCardModule } from '../card.module'; - -import { SkyKeyInfoModule } from '../../key-info'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './card.component.visual-fixture.html' -}) -class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule, - SkyCardModule, - SkyKeyInfoModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/checkbox/checkbox.component.visual-spec.js b/src/modules/checkbox/checkbox.component.visual-spec.js deleted file mode 100644 index ef26fc3de..000000000 --- a/src/modules/checkbox/checkbox.component.visual-spec.js +++ /dev/null @@ -1,13 +0,0 @@ -describe('Checkbox', function () { - 'use strict'; - - it('should match previous checkbox screenshot', function () { - return browser - .setupTest('/checkbox.html') - .compareScreenshot({ - screenshotName: 'checkbox', - selector: '#screenshot-checkbox', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/checkbox/fixtures/checkbox.component.visual-fixture.ts b/src/modules/checkbox/fixtures/checkbox.component.visual-fixture.ts deleted file mode 100644 index 4cf52390a..000000000 --- a/src/modules/checkbox/fixtures/checkbox.component.visual-fixture.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyCheckboxModule } from '../checkbox.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './checkbox.component.visual-fixture.html' -}) -class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule, - SkyCheckboxModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/chevron/chevron.component.visual-spec.js b/src/modules/chevron/chevron.component.visual-spec.js deleted file mode 100644 index cb306b2fe..000000000 --- a/src/modules/chevron/chevron.component.visual-spec.js +++ /dev/null @@ -1,13 +0,0 @@ -describe('Chevron', function () { - 'use strict'; - - it('should match previous chevron screenshot', function () { - return browser - .setupTest('/chevron.html') - .compareScreenshot({ - screenshotName: 'chevron', - selector: '#screenshot-chevron', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/chevron/fixtures/chevron.component.visual-fixture.ts b/src/modules/chevron/fixtures/chevron.component.visual-fixture.ts deleted file mode 100644 index 4552e0a42..000000000 --- a/src/modules/chevron/fixtures/chevron.component.visual-fixture.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyChevronModule } from '../chevron.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './chevron.component.visual-fixture.html' -}) -class AppComponent { - public directionUp = 'up'; - public directionDown = 'down'; -} - -@NgModule({ - imports: [ - BrowserModule, - SkyChevronModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/column-selector/column-selector-context.ts b/src/modules/column-selector/column-selector-context.ts index 8a38de8ff..9139998a3 100644 --- a/src/modules/column-selector/column-selector-context.ts +++ b/src/modules/column-selector/column-selector-context.ts @@ -1,8 +1,12 @@ +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyColumnSelectorContext { public columns: Array; public selectedColumnIds: Array; } +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyColumnSelectorModel { public id: string; public heading: string; diff --git a/src/modules/datepicker/datepicker-calendar.component.visual-spec.js b/src/modules/datepicker/datepicker-calendar.component.visual-spec.js deleted file mode 100644 index c1e37d322..000000000 --- a/src/modules/datepicker/datepicker-calendar.component.visual-spec.js +++ /dev/null @@ -1,67 +0,0 @@ -describe('Datepicker', function () { - 'use strict'; - - it('should match previous daypicker screenshot', function () { - return browser - .setupTest('/datepicker.html') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'datepicker_daypicker', - selector: '#screenshot-datepicker-calendar' - }); - }); - - it('should match previous monthpicker screenshot', function () { - return browser - .setupTest('/datepicker.html') - .pause(1000) - .click('.sky-datepicker-calendar-title') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'datepicker_monthpicker', - selector: '#screenshot-datepicker-calendar' - }); - }); - - it('should match previous yearpicker screenshot', function () { - return browser - .setupTest('/datepicker.html') - .pause(1000) - .click('.sky-datepicker-calendar-title') - .pause(1000) - .click('.sky-datepicker-calendar-title') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'datepicker_yearpicker', - selector: '#screenshot-datepicker-calendar' - }); - }); - - it('should match previous datepicker input screenshot', function () { - return browser - .setupTest('/datepicker.html') - .pause(1000) - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'datepicker_input', - selector: '#screenshot-datepicker' - }); - }); - - it('should match previous datepicker input screenshot when open', function () { - return browser - .setupTest('/datepicker.html') - .pause(1000) - .click('.sky-dropdown-button') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'datepicker_input_open', - selector: '#screenshot-datepicker' - }); - }); -}); diff --git a/src/modules/datepicker/datepicker-input.directive.ts b/src/modules/datepicker/datepicker-input.directive.ts index 7e370a2d7..591a36822 100644 --- a/src/modules/datepicker/datepicker-input.directive.ts +++ b/src/modules/datepicker/datepicker-input.directive.ts @@ -169,7 +169,7 @@ export class SkyDatepickerInputDirective implements let value = control.value; if (!value) { - return; + return undefined; } let dateValue = this.dateFormatter.getDateFromString(value, this.dateFormat); @@ -204,6 +204,8 @@ export class SkyDatepickerInputDirective implements } }; } + + return undefined; } private writeModelValue(model: Date) { diff --git a/src/modules/datepicker/daypicker.component.html b/src/modules/datepicker/daypicker.component.html index 1daaf10ba..be4c79486 100644 --- a/src/modules/datepicker/daypicker.component.html +++ b/src/modules/datepicker/daypicker.component.html @@ -54,7 +54,7 @@ - + diff --git a/src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.ts b/src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.ts deleted file mode 100644 index af279022d..000000000 --- a/src/modules/datepicker/fixtures/datepicker-calendar.component.visual-fixture.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyDatepickerModule } from '../../datepicker'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -import { FormsModule } from '@angular/forms'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './datepicker-calendar.component.visual-fixture.html' -}) -class AppComponent { - public selectedDate: Date = new Date('4/4/2017'); -} - -@NgModule({ - imports: [ - BrowserModule, - SkyDatepickerModule, - FormsModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/definition-list/definition-list.component.ts b/src/modules/definition-list/definition-list.component.ts index e31525cd6..709220d61 100644 --- a/src/modules/definition-list/definition-list.component.ts +++ b/src/modules/definition-list/definition-list.component.ts @@ -26,5 +26,6 @@ export class SkyDefinitionListComponent { this.service.defaultValue.next(value); } - constructor(private service: SkyDefinitionListService) { } + constructor( + public service: SkyDefinitionListService) { } } diff --git a/src/modules/definition-list/definition-list.component.visual-spec.js b/src/modules/definition-list/definition-list.component.visual-spec.js deleted file mode 100644 index 0565127a1..000000000 --- a/src/modules/definition-list/definition-list.component.visual-spec.js +++ /dev/null @@ -1,22 +0,0 @@ -describe('Definition list', function () { - 'use strict'; - - it('should match definition list screenshot with default settings', function () { - return browser - .setupTest('/definition-list.html') - .compareScreenshot({ - screenshotName: 'definition-list-defaults', - selector: '#screenshot-definition-list-1' - }); - }); - - it('should match definition list screenshot with custom settings', function () { - return browser - .setupTest('/definition-list.html') - .compareScreenshot({ - screenshotName: 'definition-list-overrides', - selector: '#screenshot-definition-list-2' - }); - }); - -}); diff --git a/src/modules/definition-list/fixtures/definition-list.component.visual-fixture.ts b/src/modules/definition-list/fixtures/definition-list.component.visual-fixture.ts deleted file mode 100644 index cc44d59f3..000000000 --- a/src/modules/definition-list/fixtures/definition-list.component.visual-fixture.ts +++ /dev/null @@ -1,56 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyDefinitionListModule } from '../definition-list.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './definition-list.component.visual-fixture.html' -}) -class AppComponent { - public personalInfo: {label: string, value?: string}[] = [ - { - label: 'Job title', - value: 'Engineer' - }, - { - label: 'Hobby', - value: 'Volleyball' - }, - { - label: 'Experience' - } - ]; - - public systemInfo: {label: string, value?: string}[] = [ - { - label: 'Username', - value: 'user1' - }, - { - label: 'Role', - value: 'Admin' - }, - { - label: 'Last log-in time' - } - ]; -} - -@NgModule({ - imports: [ - BrowserModule, - SkyDefinitionListModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/dropdown/dropdown.component.html b/src/modules/dropdown/dropdown.component.html index 023110517..1f516b22d 100644 --- a/src/modules/dropdown/dropdown.component.html +++ b/src/modules/dropdown/dropdown.component.html @@ -5,18 +5,18 @@ class="sky-btn sky-dropdown-button" [ngClass]="[ 'sky-dropdown-button-type-' + buttonType, - isPrimary ? 'sky-btn-primary' : 'sky-btn-default' + 'sky-btn-' + buttonStyle ]" (document:click)="windowClick()" [attr.aria-label]="label" [attr.title]="title" >
    - + - +
    diff --git a/src/modules/dropdown/dropdown.component.spec.ts b/src/modules/dropdown/dropdown.component.spec.ts index b0935c479..628e2b8ce 100644 --- a/src/modules/dropdown/dropdown.component.spec.ts +++ b/src/modules/dropdown/dropdown.component.spec.ts @@ -333,7 +333,7 @@ describe('Dropdown component', () => { expect(getDropdownBtnEl(el)).toHaveCssClass('sky-dropdown-button-type-context-menu'); }); - it('should have a default button background of "sky-btn-default" aka isPrimary is false', () => { + it('should have a default button background of "sky-btn-default"', () => { let fixture = TestBed.createComponent(DropdownTestComponent); let el: Element = fixture.nativeElement; @@ -342,12 +342,12 @@ describe('Dropdown component', () => { expect(getDropdownBtnEl(el)).toHaveCssClass('sky-btn-default'); }); - it('should set the CSS class to primary when isPrimary is true', () => { + it('should set the CSS class based on buttonStyle changes', () => { let fixture = TestBed.createComponent(DropdownTestComponent); let cmp = fixture.componentInstance; let el: Element = fixture.nativeElement; - cmp.isPrimary = true; + cmp.buttonStyle = 'primary'; fixture.detectChanges(); diff --git a/src/modules/dropdown/dropdown.component.ts b/src/modules/dropdown/dropdown.component.ts index 0c2a2c1b1..dd6f12d3b 100644 --- a/src/modules/dropdown/dropdown.component.ts +++ b/src/modules/dropdown/dropdown.component.ts @@ -47,12 +47,12 @@ export class SkyDropdownComponent implements OnDestroy { public alignment: string = 'left'; @Input() - public get isPrimary(): boolean { - return this._isPrimary; + public get buttonStyle(): string{ + return this._buttonStyle || 'default'; } - public set isPrimary(flag: boolean) { - this._isPrimary = flag; + public set buttonStyle(value: string) { + this._buttonStyle = value; } private open = false; @@ -61,7 +61,7 @@ export class SkyDropdownComponent implements OnDestroy { private _buttonType: string; - private _isPrimary: boolean; + private _buttonStyle: string; private _trigger: string; diff --git a/src/modules/dropdown/dropdown.component.visual-spec.js b/src/modules/dropdown/dropdown.component.visual-spec.js deleted file mode 100644 index 9e2279793..000000000 --- a/src/modules/dropdown/dropdown.component.visual-spec.js +++ /dev/null @@ -1,51 +0,0 @@ -describe('Dropdown', function () { - 'use strict'; - - it('should match dropdown button screenshot when closed', function () { - return browser - .setupTest('/dropdown.html') - .compareScreenshot({ - screenshotName: 'dropdown-button-closed', - selector: '#screenshot-dropdown-button' - }); - }); - - it('should match dropdown button screenshot when open', function () { - return browser - .setupTest('/dropdown.html') - .click('#screenshot-dropdown-button .sky-dropdown-button') - .compareScreenshot({ - screenshotName: 'dropdown-button-open', - selector: '#screenshot-dropdown-button' - }); - }); - - it('should match dropdown context menu screenshot when closed', function () { - return browser - .setupTest('/dropdown.html') - .compareScreenshot({ - screenshotName: 'dropdown-context-menu-closed', - selector: '#screenshot-dropdown-context-menu' - }); - }); - - it('should match dropdown context menu screenshot when open', function () { - return browser - .setupTest('/dropdown.html') - .click('#screenshot-dropdown-context-menu .sky-dropdown-button') - .compareScreenshot({ - screenshotName: 'dropdown-context-menu-open', - selector: '#screenshot-dropdown-context-menu' - }); - }); - - it('should match dropdown screenshot when before a relative element', function () { - return browser - .setupTest('/dropdown.html') - .click('#screenshot-dropdown-z-index .sky-dropdown-button') - .compareScreenshot({ - screenshotName: 'dropdown_z_index', - selector: '#screenshot-dropdown-z-index' - }); - }); -}); diff --git a/src/modules/dropdown/fixtures/dropdown-parent.component.fixture.ts b/src/modules/dropdown/fixtures/dropdown-parent.component.fixture.ts index 486f042ed..d1c34abfe 100644 --- a/src/modules/dropdown/fixtures/dropdown-parent.component.fixture.ts +++ b/src/modules/dropdown/fixtures/dropdown-parent.component.fixture.ts @@ -8,5 +8,5 @@ export class DropdownParentTestComponent { public trigger: String; public buttonType: String; public myTitle: string; - public isPrimary: boolean; + public buttonStyle: String; } diff --git a/src/modules/dropdown/fixtures/dropdown.component.fixture.html b/src/modules/dropdown/fixtures/dropdown.component.fixture.html index 537bfcc60..877b9ddf9 100644 --- a/src/modules/dropdown/fixtures/dropdown.component.fixture.html +++ b/src/modules/dropdown/fixtures/dropdown.component.fixture.html @@ -4,7 +4,7 @@ [trigger]="trigger" [title]="myTitle" [alignment]="alignment" - [isPrimary]="isPrimary"> + [buttonStyle]="buttonStyle"> Show dropdown diff --git a/src/modules/dropdown/fixtures/dropdown.component.fixture.ts b/src/modules/dropdown/fixtures/dropdown.component.fixture.ts index 5b8cceb10..b10a4a2d9 100644 --- a/src/modules/dropdown/fixtures/dropdown.component.fixture.ts +++ b/src/modules/dropdown/fixtures/dropdown.component.fixture.ts @@ -9,5 +9,5 @@ export class DropdownTestComponent { public buttonType: String; public myTitle: string; public alignment: string = 'left'; - public isPrimary: boolean; + public buttonStyle: string; } diff --git a/src/modules/dropdown/fixtures/dropdown.component.visual-fixture.ts b/src/modules/dropdown/fixtures/dropdown.component.visual-fixture.ts deleted file mode 100644 index 69e6c49a9..000000000 --- a/src/modules/dropdown/fixtures/dropdown.component.visual-fixture.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyDropdownModule } from '../dropdown.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './dropdown.component.visual-fixture.html' -}) -class AppComponent { - public dropdownOpen = false; - - public click() { - this.dropdownOpen = true; - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyDropdownModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/error/error-modal-config.ts b/src/modules/error/error-modal-config.ts index f79fc6de7..958c19f47 100644 --- a/src/modules/error/error-modal-config.ts +++ b/src/modules/error/error-modal-config.ts @@ -1,3 +1,4 @@ +/* istanbul ignore next */ export class ErrorModalConfig { public errorTitle: string; public errorDescription: string; diff --git a/src/modules/error/error.component.visual-spec.js b/src/modules/error/error.component.visual-spec.js deleted file mode 100644 index 8f2ab886f..000000000 --- a/src/modules/error/error.component.visual-spec.js +++ /dev/null @@ -1,26 +0,0 @@ -describe('Error', function () { - 'use strict'; - - it('should match previous screenshot for broken type', function () { - return browser - .setupTest('/error.html') - .compareScreenshot({ - screenshotName: 'error-images', - selector: '#screenshot-error-img', - checkAccessibility: true - }); - }); - - it('should match previous error modal form screenshot', function () { - return browser - .setupTest('/error.html') - .click('.sky-test-error-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'error-modal-form', - selector: '.sky-modal', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/error/fixtures/error.component.visual-fixture.ts b/src/modules/error/fixtures/error.component.visual-fixture.ts deleted file mode 100644 index 2ce06a18e..000000000 --- a/src/modules/error/fixtures/error.component.visual-fixture.ts +++ /dev/null @@ -1,43 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyErrorModule } from '../error.module'; -import { Bootstrapper } from '../../../../visual/bootstrapper'; -import { ErrorModalConfig } from '../error-modal-config'; -import { SkyErrorModalService } from '../error-modal.service'; -import { SkyModalModule } from '../../modal/modal.module'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './error.component.visual-fixture.html' -}) -class AppComponent { - constructor(private modal: SkyErrorModalService) { } - - public openModal() { - const config: ErrorModalConfig = { - errorTitle: 'Some error title', - errorDescription: 'Description of error', - errorCloseText: 'Close button text' - }; - - this.modal.open(config); - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyErrorModule, - SkyModalModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/error/index.ts b/src/modules/error/index.ts index e2ef3a854..e06252a08 100644 --- a/src/modules/error/index.ts +++ b/src/modules/error/index.ts @@ -3,4 +3,5 @@ export { SkyErrorDescriptionComponent } from './error-description.component'; export { SkyErrorImageComponent } from './error-image.component'; export { SkyErrorTitleComponent } from './error-title.component'; export { SkyErrorModule } from './error.module'; +export { ErrorModalConfig } from './error-modal-config'; export { SkyErrorModalService } from './error-modal.service'; diff --git a/src/modules/fileattachments/file-drop.component.visual-spec.js b/src/modules/fileattachments/file-drop.component.visual-spec.js deleted file mode 100644 index 202dcc8a4..000000000 --- a/src/modules/fileattachments/file-drop.component.visual-spec.js +++ /dev/null @@ -1,23 +0,0 @@ -describe('File drop', function () { - 'use strict'; - - it('should match the file drop control', function () { - return browser - .setupTest('/fileattachments.html') - .compareScreenshot({ - screenshotName: 'file-drop', - selector: '#screenshot-file-drop' - }); - }); - - it('should match the file drop control when no links allowed', function () { - return browser - .setupTest('/fileattachments.html') - .click('.sky-test-allow-links') - .pause(1000) - .compareScreenshot({ - screenshotName: 'file_drop_nolink', - selector: '#screenshot-file-drop' - }); - }); -}); diff --git a/src/modules/fileattachments/file-item.component.ts b/src/modules/fileattachments/file-item.component.ts index b78b07bd9..d5009e674 100644 --- a/src/modules/fileattachments/file-item.component.ts +++ b/src/modules/fileattachments/file-item.component.ts @@ -32,7 +32,7 @@ export class SkyFileItemComponent implements DoCheck { private otherCls: string; - private differ: KeyValueDiffer; + private differ: KeyValueDiffer; public ngDoCheck() { let changes = this.differ.diff(this.fileItem); diff --git a/src/modules/filter/filter.component.visual-spec.js b/src/modules/filter/filter.component.visual-spec.js deleted file mode 100644 index aedfbec8f..000000000 --- a/src/modules/filter/filter.component.visual-spec.js +++ /dev/null @@ -1,49 +0,0 @@ -describe('Filter', function () { - 'use strict'; - - it('should match previous screenshot for filter button', function () { - return browser - .setupTest('/filter.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'filter_button', - selector: '#screenshot-filter-button', - checkAccessibility: true - }); - }); - - it('should match previous screenshot for active filter button', function () { - return browser - .setupTest('/filter.html') - .pause(1000) - .click('.sky-btn-default') - .pause(1000) - .compareScreenshot({ - screenshotName: 'filter_button_active', - selector: '#screenshot-filter-button', - checkAccessibility: true - }); - }); - - it('should match previous screenshot for filter summary', function () { - return browser - .setupTest('/filter.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'filter_summary', - selector: '#screenshot-filter-summary', - checkAccessibility: true - }); - }); - - it('should match previous screenshot for filter inline', function () { - return browser - .setupTest('/filter.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'filter_inline', - selector: '#screenshot-filter-inline', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/filter/fixtures/filter.component.visual-fixture.ts b/src/modules/filter/fixtures/filter.component.visual-fixture.ts deleted file mode 100644 index 1a9354e25..000000000 --- a/src/modules/filter/fixtures/filter.component.visual-fixture.ts +++ /dev/null @@ -1,44 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyFilterModule } from '../filter.module'; - -import { SkyToolbarModule } from '../../toolbar'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './filter.component.visual-fixture.html' -}) -class AppComponent { - public filtersActive: boolean = false; - - public appliedFilters: Array = [ - { - label: 'hide orange', - dismissible: false - }, - { - label: 'berry fruit type', - dismissible: true - } - ]; -} - -@NgModule({ - imports: [ - BrowserModule, - SkyFilterModule, - SkyToolbarModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/grid/fixtures/grid-empty.component.fixture.html b/src/modules/grid/fixtures/grid-empty.component.fixture.html index 90cc9551e..a129d3b06 100644 --- a/src/modules/grid/fixtures/grid-empty.component.fixture.html +++ b/src/modules/grid/fixtures/grid-empty.component.fixture.html @@ -1,3 +1,3 @@ - +{{value}} diff --git a/src/modules/grid/fixtures/grid.component.fixture.html b/src/modules/grid/fixtures/grid.component.fixture.html index 3aef98ca0..1aca8906f 100644 --- a/src/modules/grid/fixtures/grid.component.fixture.html +++ b/src/modules/grid/fixtures/grid.component.fixture.html @@ -19,10 +19,10 @@ [width]="150" [isSortable]="false" [search]="searchFunction"> - + - + diff --git a/src/modules/grid/grid-cell.component.ts b/src/modules/grid/grid-cell.component.ts index bd457ce8c..64daaf880 100644 --- a/src/modules/grid/grid-cell.component.ts +++ b/src/modules/grid/grid-cell.component.ts @@ -15,7 +15,7 @@ import { getData } from '../list/helpers'; @Component({ selector: 'sky-grid-cell', - template: '', + template: '', styleUrls: ['./grid-cell.component.scss'], changeDetection: ChangeDetectionStrategy.OnPush }) diff --git a/src/modules/grid/grid.component.html b/src/modules/grid/grid.component.html index 35f8a4478..fb2f02488 100644 --- a/src/modules/grid/grid.component.html +++ b/src/modules/grid/grid.component.html @@ -46,4 +46,4 @@
    - +{{value}} diff --git a/src/modules/grid/grid.component.visual-spec.js b/src/modules/grid/grid.component.visual-spec.js deleted file mode 100644 index f34fba22c..000000000 --- a/src/modules/grid/grid.component.visual-spec.js +++ /dev/null @@ -1,42 +0,0 @@ -describe('grid component', function () { - 'use strict'; - - it('should display grid', function () { - return browser - .setupTest('/grid.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'grid', - selector: '#screenshot-grid', - checkAccessibility: true - }); - }); - - it('should display grid with descending sort indication', function () { - return browser - .setupTest('/grid.html') - .pause(1000) - .click('th') - .pause(1000) - .compareScreenshot({ - screenshotName: 'grid_sort_desc', - selector: '#screenshot-grid', - checkAccessibility: true - }); - }); - - it('should display grid with ascending sort indication', function () { - return browser - .setupTest('/grid.html') - .pause(1000) - .click('th') - .pause(1000) - .click('th') - .pause(1000) - .compareScreenshot({ - screenshotName: 'grid_sort_asc', - selector: '#screenshot-grid', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/key-info/fixtures/key-info.component.visual-fixture.ts b/src/modules/key-info/fixtures/key-info.component.visual-fixture.ts deleted file mode 100644 index 554f6b59c..000000000 --- a/src/modules/key-info/fixtures/key-info.component.visual-fixture.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyKeyInfoModule } from '../key-info.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './key-info.component.visual-fixture.html' -}) -export class AppComponent {} - -@NgModule({ - imports: [ - BrowserModule, - SkyKeyInfoModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/key-info/key-info.component.visual-spec.js b/src/modules/key-info/key-info.component.visual-spec.js deleted file mode 100644 index b762ef885..000000000 --- a/src/modules/key-info/key-info.component.visual-spec.js +++ /dev/null @@ -1,14 +0,0 @@ -describe('KeyInfo', function () { - 'use strict'; - - it('should match previous key-info screenshot', function () { - return browser - .setupTest('/key-info.html') - .compareScreenshot({ - screenshotName: 'key-info', - selector: '#screenshot-key-info', - checkAccessibility: true - }); - }); - -}); diff --git a/src/modules/label/fixtures/label.component.visual-fixture.ts b/src/modules/label/fixtures/label.component.visual-fixture.ts deleted file mode 100644 index cc2cccfd5..000000000 --- a/src/modules/label/fixtures/label.component.visual-fixture.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyLabelModule } from '../label.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './label.component.visual-fixture.html' -}) -class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule, - SkyLabelModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/label/label.component.visual-spec.js b/src/modules/label/label.component.visual-spec.js deleted file mode 100644 index eac62a9fc..000000000 --- a/src/modules/label/label.component.visual-spec.js +++ /dev/null @@ -1,13 +0,0 @@ -describe('Label', function () { - 'use strict'; - - it('should match previous label screenshot', function () { - return browser - .setupTest('/label.html') - .compareScreenshot({ - screenshotName: 'labels-all', - selector: '#screenshot-label', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/list-column-selector-action/list-column-selector-action.spec.ts b/src/modules/list-column-selector-action/list-column-selector-action.spec.ts index 39ee6325e..637b72f7a 100644 --- a/src/modules/list-column-selector-action/list-column-selector-action.spec.ts +++ b/src/modules/list-column-selector-action/list-column-selector-action.spec.ts @@ -131,13 +131,11 @@ describe('List column selector action', () => { it('should open the appropriate modal on click and apply column changes on save', fakeAsync(() => { - tick(); fixture.detectChanges(); tick(); getChooseColumnsAction().click(); tick(); - fixture.detectChanges(); let checkboxLabelEl = document @@ -148,64 +146,52 @@ describe('List column selector action', () => { checkboxLabelEl.item(0).click(); tick(); - fixture.detectChanges(); let submitButtonEl = document.querySelector('.sky-modal .sky-btn-primary') as HTMLButtonElement; submitButtonEl.click(); - fixture.detectChanges(); tick(); component.grid.gridState.take(1).subscribe((gridState) => { expect(gridState.displayedColumns.items.length).toBe(2); }); - fixture.detectChanges(); tick(); })); it('should keep previous columns on cancel', fakeAsync(() => { - tick(); fixture.detectChanges(); tick(); getChooseColumnsAction().click(); tick(); - fixture.detectChanges(); let checkboxLabelEl = document.querySelector('.sky-modal .sky-list-view-checklist-item input') as HTMLElement; checkboxLabelEl.click(); tick(); - fixture.detectChanges(); let cancelButtonEl = document.querySelector('.sky-modal [sky-cmp-id="cancel"]') as HTMLButtonElement; cancelButtonEl.click(); - fixture.detectChanges(); tick(); component.grid.gridState.take(1).subscribe((gridState) => { expect(gridState.displayedColumns.items.length).toBe(3); }); - fixture.detectChanges(); tick(); })); it('should not appear if not in grid view', fakeAsync(() => { tick(); - fixture.detectChanges(); - tick(); - dispatcher.viewsSetActive('other'); tick(); - fixture.detectChanges(); - tick(); + /* tslint:disable */ let query = '.sky-list-toolbar-container .sky-toolbar-item .sky-list-secondary-actions .sky-dropdown .sky-dropdown-menu sky-list-secondary-action'; diff --git a/src/modules/list-filters/fixtures/list-filter-inline.component.fixture.html b/src/modules/list-filters/fixtures/list-filter-inline.component.fixture.html index 4887e23ff..4c118af15 100644 --- a/src/modules/list-filters/fixtures/list-filter-inline.component.fixture.html +++ b/src/modules/list-filters/fixtures/list-filter-inline.component.fixture.html @@ -5,7 +5,7 @@ [filter]="fruitTypeFilterFunction" value="any" defaultValue="any"> - + - + diff --git a/src/modules/list-filters/list-filter-button.component.html b/src/modules/list-filters/list-filter-button.component.html index 336a7b6b8..6c2faf8ad 100644 --- a/src/modules/list-filters/list-filter-button.component.html +++ b/src/modules/list-filters/list-filter-button.component.html @@ -1,3 +1,3 @@ - + diff --git a/src/modules/list-filters/list-filter-inline-item-renderer.component.ts b/src/modules/list-filters/list-filter-inline-item-renderer.component.ts index 0e82ea2a9..36676b152 100644 --- a/src/modules/list-filters/list-filter-inline-item-renderer.component.ts +++ b/src/modules/list-filters/list-filter-inline-item-renderer.component.ts @@ -9,7 +9,7 @@ import { @Component({ selector: 'sky-list-filter-inline-item-renderer', - template: '' + template: '' }) export class SkyListFilterInlineItemRendererComponent implements OnInit { @Input() diff --git a/src/modules/list-filters/list-filter-inline.component.ts b/src/modules/list-filters/list-filter-inline.component.ts index fc0fe2509..8ba7b16be 100644 --- a/src/modules/list-filters/list-filter-inline.component.ts +++ b/src/modules/list-filters/list-filter-inline.component.ts @@ -71,5 +71,4 @@ export class SkyListFilterInlineComponent implements AfterContentInit { }); }); } - } diff --git a/src/modules/list-secondary-actions/list-secondary-actions.component.html b/src/modules/list-secondary-actions/list-secondary-actions.component.html index f19df53ab..bb21653bf 100644 --- a/src/modules/list-secondary-actions/list-secondary-actions.component.html +++ b/src/modules/list-secondary-actions/list-secondary-actions.component.html @@ -1,4 +1,4 @@ - + diff --git a/src/modules/list-secondary-actions/list-secondary-actions.component.visual-spec.js b/src/modules/list-secondary-actions/list-secondary-actions.component.visual-spec.js deleted file mode 100644 index 2a4aa98b4..000000000 --- a/src/modules/list-secondary-actions/list-secondary-actions.component.visual-spec.js +++ /dev/null @@ -1,16 +0,0 @@ -describe('list-secondary-actions component', function () { - 'use strict'; - - it('should display toolbar with secondary actions', function () { - return browser - .setupTest('/list-secondary-actions.html') - .pause(1000) - .click('.sky-list-secondary-actions .sky-dropdown-button') - .pause(1000) - .compareScreenshot({ - screenshotName: 'list_secondary_actions', - selector: '#screenshot-list-secondary-actions', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/list-toolbar/fixtures/list-toolbar.component.fixture.html b/src/modules/list-toolbar/fixtures/list-toolbar.component.fixture.html index 54a7902c7..4be62f48d 100644 --- a/src/modules/list-toolbar/fixtures/list-toolbar.component.fixture.html +++ b/src/modules/list-toolbar/fixtures/list-toolbar.component.fixture.html @@ -5,10 +5,10 @@ [toolbarType]="toolbarType" #toolbar> - + Custom Item - + Custom Item 2 - + diff --git a/src/modules/list-toolbar/list-toolbar-item-renderer.component.ts b/src/modules/list-toolbar/list-toolbar-item-renderer.component.ts index b045d88ff..5e598f461 100644 --- a/src/modules/list-toolbar/list-toolbar-item-renderer.component.ts +++ b/src/modules/list-toolbar/list-toolbar-item-renderer.component.ts @@ -2,7 +2,7 @@ import { Component, ViewContainerRef, ViewChild, Input, TemplateRef, OnInit} fro @Component({ selector: 'sky-list-toolbar-item-renderer', - template: '' + template: '' }) export class SkyListToolbarItemRendererComponent implements OnInit { @Input() public template: TemplateRef; diff --git a/src/modules/list-toolbar/list-toolbar.component.html b/src/modules/list-toolbar/list-toolbar.component.html index 4ceba4000..37f4f532e 100644 --- a/src/modules/list-toolbar/list-toolbar.component.html +++ b/src/modules/list-toolbar/list-toolbar.component.html @@ -67,7 +67,7 @@
    - + - + - + diff --git a/src/modules/list-toolbar/state/config/config.orchestrator.ts b/src/modules/list-toolbar/state/config/config.orchestrator.ts index 4c1197709..a2b44afc9 100644 --- a/src/modules/list-toolbar/state/config/config.orchestrator.ts +++ b/src/modules/list-toolbar/state/config/config.orchestrator.ts @@ -8,7 +8,9 @@ import { export class ListToolbarConfigOrchestrator extends ListToolbarStateOrchestrator { + /* istanbul ignore next */ constructor() { + super(); this diff --git a/src/modules/list-view-checklist/list-view-checklist.component.html b/src/modules/list-view-checklist/list-view-checklist.component.html index 94d61e981..7b98ba363 100644 --- a/src/modules/list-view-checklist/list-view-checklist.component.html +++ b/src/modules/list-view-checklist/list-view-checklist.component.html @@ -14,14 +14,14 @@
    - + - + diff --git a/src/modules/list-view-checklist/list-view-checklist.component.ts b/src/modules/list-view-checklist/list-view-checklist.component.ts index d239a6984..cf9b88fff 100644 --- a/src/modules/list-view-checklist/list-view-checklist.component.ts +++ b/src/modules/list-view-checklist/list-view-checklist.component.ts @@ -194,6 +194,8 @@ export class SkyListViewChecklistComponent extends ListViewComponent implements return true; } } + + return false; }; } diff --git a/src/modules/list-view-checklist/list-view-checklist.component.visual-spec.js b/src/modules/list-view-checklist/list-view-checklist.component.visual-spec.js deleted file mode 100644 index d114979ca..000000000 --- a/src/modules/list-view-checklist/list-view-checklist.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('list-view-checklist component', function () { - 'use strict'; - - it('should display checklist view', function () { - return browser - .setupTest('/list-view-checklist.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'list_view_checklist', - selector: '#screenshot-list-view-checklist' - }); - }); - - it('should display checklist view with checked', function () { - return browser - .setupTest('/list-view-checklist.html') - .pause(1000) - .click('sky-checkbox') - .pause(1000) - .compareScreenshot({ - screenshotName: 'list_view_checklist_checked', - selector: '#screenshot-list-view-checklist' - }); - }); -}); diff --git a/src/modules/list-view-checklist/state/items/items.orchestrator.ts b/src/modules/list-view-checklist/state/items/items.orchestrator.ts index df938ccf0..0ee18142d 100644 --- a/src/modules/list-view-checklist/state/items/items.orchestrator.ts +++ b/src/modules/list-view-checklist/state/items/items.orchestrator.ts @@ -18,6 +18,7 @@ let moment = require('moment'); export class ListViewChecklistItemsOrchestrator extends ChecklistStateOrchestrator> { + /* istanbul ignore next */ constructor() { super(); this.register(ListViewChecklistItemsLoadAction, this.load); diff --git a/src/modules/list-view-grid/fixtures/list-view-grid-display.component.fixture.html b/src/modules/list-view-grid/fixtures/list-view-grid-display.component.fixture.html index bc2351ac5..6ce8d39ec 100644 --- a/src/modules/list-view-grid/fixtures/list-view-grid-display.component.fixture.html +++ b/src/modules/list-view-grid/fixtures/list-view-grid-display.component.fixture.html @@ -1,7 +1,7 @@ - + {{row.column2}} @@ -10,10 +10,10 @@ - + - + diff --git a/src/modules/list-view-grid/fixtures/list-view-grid.component.fixture.html b/src/modules/list-view-grid/fixtures/list-view-grid.component.fixture.html index b589f6ff0..a8f347d26 100644 --- a/src/modules/list-view-grid/fixtures/list-view-grid.component.fixture.html +++ b/src/modules/list-view-grid/fixtures/list-view-grid.component.fixture.html @@ -9,7 +9,7 @@ > - + {{row.column2}} @@ -18,10 +18,10 @@ - + - + diff --git a/src/modules/list-view-grid/list-view-grid.component.ts b/src/modules/list-view-grid/list-view-grid.component.ts index 53e204a3f..8fdfeae74 100644 --- a/src/modules/list-view-grid/list-view-grid.component.ts +++ b/src/modules/list-view-grid/list-view-grid.component.ts @@ -143,6 +143,9 @@ export class SkyListViewGridComponent if (s.sort && s.sort.fieldSelectors) { return s.sort.fieldSelectors[0]; } + /* istanbul ignore next */ + /* sanity check */ + return undefined; }).distinctUntilChanged(); this.gridState.map(s => s.columns.items) diff --git a/src/modules/list-view-grid/state/columns/columns.orchestrator.ts b/src/modules/list-view-grid/state/columns/columns.orchestrator.ts index 37eabb400..4f0fd32bc 100644 --- a/src/modules/list-view-grid/state/columns/columns.orchestrator.ts +++ b/src/modules/list-view-grid/state/columns/columns.orchestrator.ts @@ -8,6 +8,7 @@ let moment = require('moment'); export class ListViewGridColumnsOrchestrator extends GridStateOrchestrator> { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list-view-grid/state/displayed-columns/displayed-columns.orchestrator.ts b/src/modules/list-view-grid/state/displayed-columns/displayed-columns.orchestrator.ts index 967fef99e..dbc03b970 100644 --- a/src/modules/list-view-grid/state/displayed-columns/displayed-columns.orchestrator.ts +++ b/src/modules/list-view-grid/state/displayed-columns/displayed-columns.orchestrator.ts @@ -8,6 +8,7 @@ let moment = require('moment'); export class ListViewDisplayedGridColumnsOrchestrator extends GridStateOrchestrator> { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/fixtures/list-filtered.component.fixture.html b/src/modules/list/fixtures/list-filtered.component.fixture.html index 5797d8c1f..81db4645f 100644 --- a/src/modules/list/fixtures/list-filtered.component.fixture.html +++ b/src/modules/list/fixtures/list-filtered.component.fixture.html @@ -6,13 +6,13 @@ > - + {{row.column1}} - + {{row.column2}} - + {{row.column3}} diff --git a/src/modules/list/fixtures/list-selected.component.fixture.html b/src/modules/list/fixtures/list-selected.component.fixture.html index 0b33099ee..75fd10279 100644 --- a/src/modules/list/fixtures/list-selected.component.fixture.html +++ b/src/modules/list/fixtures/list-selected.component.fixture.html @@ -6,13 +6,13 @@ > - + {{row.column1}} - + {{row.column2}} - + {{row.column3}} diff --git a/src/modules/list/fixtures/list.component.fixture.html b/src/modules/list/fixtures/list.component.fixture.html index 9d7049075..cafaaef87 100644 --- a/src/modules/list/fixtures/list.component.fixture.html +++ b/src/modules/list/fixtures/list.component.fixture.html @@ -6,13 +6,13 @@ - + {{row.column1}} - + {{row.column2}} - + {{row.column3}} diff --git a/src/modules/list/state/filters/filters.orchestrator.ts b/src/modules/list/state/filters/filters.orchestrator.ts index e7e7e4ee0..25bda7be2 100644 --- a/src/modules/list/state/filters/filters.orchestrator.ts +++ b/src/modules/list/state/filters/filters.orchestrator.ts @@ -5,6 +5,7 @@ import { } from './actions'; export class ListFiltersOrchestrator extends ListStateOrchestrator { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/items/items.orchestrator.ts b/src/modules/list/state/items/items.orchestrator.ts index c8d2b6136..0fa6a234f 100644 --- a/src/modules/list/state/items/items.orchestrator.ts +++ b/src/modules/list/state/items/items.orchestrator.ts @@ -9,6 +9,7 @@ import { } from './actions'; export class ListItemsOrchestrator extends ListStateOrchestrator> { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/paging/paging.orchestrator.ts b/src/modules/list/state/paging/paging.orchestrator.ts index e912f0100..367eb3dae 100644 --- a/src/modules/list/state/paging/paging.orchestrator.ts +++ b/src/modules/list/state/paging/paging.orchestrator.ts @@ -7,6 +7,7 @@ import { } from './actions'; export class ListPagingOrchestrator extends ListStateOrchestrator { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/search/search.orchestrator.ts b/src/modules/list/state/search/search.orchestrator.ts index 1b3a4d9aa..a9683e623 100644 --- a/src/modules/list/state/search/search.orchestrator.ts +++ b/src/modules/list/state/search/search.orchestrator.ts @@ -5,6 +5,7 @@ import { ListSearchSetFunctionsAction } from './set-functions.action'; import { ListSearchSetFieldSelectorsAction } from './set-field-selectors.action'; export class ListSearchOrchestrator extends ListStateOrchestrator { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/selected/selected.orchestrator.ts b/src/modules/list/state/selected/selected.orchestrator.ts index 83c96c376..243bb8de3 100644 --- a/src/modules/list/state/selected/selected.orchestrator.ts +++ b/src/modules/list/state/selected/selected.orchestrator.ts @@ -12,6 +12,7 @@ import { let moment = require('moment'); export class ListSelectedOrchestrator extends ListStateOrchestrator> { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/sort/sort.orchestrator.ts b/src/modules/list/state/sort/sort.orchestrator.ts index 8a7f9614c..aa6a50b99 100644 --- a/src/modules/list/state/sort/sort.orchestrator.ts +++ b/src/modules/list/state/sort/sort.orchestrator.ts @@ -8,6 +8,7 @@ import { } from './actions'; export class ListSortOrchestrator extends ListStateOrchestrator { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/toolbar/toolbar.orchestrator.ts b/src/modules/list/state/toolbar/toolbar.orchestrator.ts index d97f16077..c15ed0dec 100644 --- a/src/modules/list/state/toolbar/toolbar.orchestrator.ts +++ b/src/modules/list/state/toolbar/toolbar.orchestrator.ts @@ -9,7 +9,7 @@ import { export class ListToolbarOrchestrator extends ListStateOrchestrator { - + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/list/state/views/views.orchestrator.ts b/src/modules/list/state/views/views.orchestrator.ts index 98e9e1c1e..baa507e1f 100644 --- a/src/modules/list/state/views/views.orchestrator.ts +++ b/src/modules/list/state/views/views.orchestrator.ts @@ -4,6 +4,7 @@ import { ListViewsLoadAction } from './load.action'; import { ListViewsSetActiveAction } from './set-active.action'; export class ListViewsOrchestrator extends ListStateOrchestrator { + /* istanbul ignore next */ constructor() { super(); diff --git a/src/modules/modal/fixtures/modal.component.visual-fixture.ts b/src/modules/modal/fixtures/modal.component.visual-fixture.ts deleted file mode 100644 index 702c478cb..000000000 --- a/src/modules/modal/fixtures/modal.component.visual-fixture.ts +++ /dev/null @@ -1,75 +0,0 @@ -import { Component, NgModule, ViewContainerRef } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyModalModule, SkyModalService } from '../'; - -import { ModalDemoComponent } from './modal.visual.content'; -import { ModalLargeDemoComponent } from './modal-large.visual.content'; -import { ModalFullPageDemoComponent } from './modal-fullpage.visual.content'; -import { Bootstrapper } from '../../../../visual/bootstrapper'; -import { ModalContentDemoComponent } from './modal-content.visual.content'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './modal.component.visual-fixture.html' -}) -class AppComponent { - constructor(public viewContainerRef: ViewContainerRef, private modal: SkyModalService) { } - - public openModal() { - this.modal.open(ModalDemoComponent, { 'providers': [] }); - } - - public openLargeModal() { - this.modal.open(ModalLargeDemoComponent, { 'providers': [] }); - } - - public openFullScreenModal() { - this.modal.open(ModalFullPageDemoComponent, { 'providers': [], 'fullPage': true }); - } - - public openContentModal() { - this.modal.open(ModalContentDemoComponent); - } - - public openSmallSizeModal() { - this.modal.open( - ModalDemoComponent, { 'providers': [], 'fullPage': false , 'size': 'small'}); - } - - public openMediumSizeModal() { - this.modal.open( - ModalDemoComponent, { 'providers': [], 'fullPage': false , 'size': 'medium'}); - } - - public openLargeSizeModal() { - this.modal.open( - ModalDemoComponent, { 'providers': [], 'fullPage': false , 'size': 'large'}); - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyModalModule - ], - declarations: [ - AppComponent, - ModalDemoComponent, - ModalLargeDemoComponent, - ModalFullPageDemoComponent, - ModalContentDemoComponent - ], - bootstrap: [ - AppComponent - ], - entryComponents: [ - ModalDemoComponent, - ModalLargeDemoComponent, - ModalFullPageDemoComponent, - ModalContentDemoComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/modal/modal-close-args.ts b/src/modules/modal/modal-close-args.ts index e0664db0d..b5d90bb5f 100644 --- a/src/modules/modal/modal-close-args.ts +++ b/src/modules/modal/modal-close-args.ts @@ -1,3 +1,5 @@ +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyModalCloseArgs { public reason: string; public data: any; diff --git a/src/modules/modal/modal.component.visual-spec.js b/src/modules/modal/modal.component.visual-spec.js deleted file mode 100644 index d07189efc..000000000 --- a/src/modules/modal/modal.component.visual-spec.js +++ /dev/null @@ -1,120 +0,0 @@ -describe('Modal', function () { - 'use strict'; - - it('should match previous modal screenshot', function () { - return browser - .setupTest('/modal.html') - .click('.sky-btn-primary') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous modal screenshot on small screens', function () { - return browser - .setupTest('/modal.html', 480) - .click('.sky-btn-primary') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_small', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous large modal screenshot', function () { - return browser - .setupTest('/modal.html') - .click('.sky-test-large-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_large', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous large modal screenshot on mobile', function () { - return browser - .setupTest('/modal.html', 480) - .click('.sky-test-large-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_large_mobile', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous screenshot of modal without header or footer', function () { - return browser - .setupTest('/modal.html') - .click('.sky-test-content-only') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_content_only', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous small size modal screenshot', function () { - return browser - .setupTest('/modal.html') - .click('.sky-test-small-size-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_small_size', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous medium size modal screenshot', function () { - return browser - .setupTest('/modal.html') - .click('.sky-test-medium-size-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_medium_size', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous large size modal screenshot', function () { - return browser - .setupTest('/modal.html') - .click('.sky-test-large-size-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_large_size', - selector: '.sky-modal', - checkAccessibility: true - }); - }); - - it('should match previous large size modal screenshot on intermediate screens', function () { - return browser - .setupTest('/modal.html', 800) - .click('.sky-test-large-size-modal') - .moveCursorOffScreen() - .pause(1000) - .compareScreenshot({ - screenshotName: 'modal_large_size_bounded', - selector: '.sky-modal', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/mutation/mutation-observer-service.spec.ts b/src/modules/mutation/mutation-observer-service.spec.ts new file mode 100644 index 000000000..05ded2dfb --- /dev/null +++ b/src/modules/mutation/mutation-observer-service.spec.ts @@ -0,0 +1,13 @@ +import { TestBed } from '@angular/core/testing'; +import { MutationObserverService } from './mutation-observer-service'; + +describe('Mutation observer service', () => { + + it('should return a new instance of a mutation observer', () => { + let service = new MutationObserverService(); + let observer = service.create((mutations: MutationRecord[]) => 0); + + expect(observer).not.toBe(undefined); + expect(observer).toEqual(jasmine.any(MutationObserver)); + }); +}); diff --git a/src/modules/mutation/mutation-observer-service.ts b/src/modules/mutation/mutation-observer-service.ts new file mode 100644 index 000000000..a715af833 --- /dev/null +++ b/src/modules/mutation/mutation-observer-service.ts @@ -0,0 +1,8 @@ +import { Injectable } from '@angular/core'; + +@Injectable() +export class MutationObserverService { + public create(callback: any): MutationObserver { + return new MutationObserver(callback); + } +} diff --git a/src/modules/navbar/fixtures/navbar.component.visual-fixture.ts b/src/modules/navbar/fixtures/navbar.component.visual-fixture.ts deleted file mode 100644 index 030201cac..000000000 --- a/src/modules/navbar/fixtures/navbar.component.visual-fixture.ts +++ /dev/null @@ -1,31 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyNavbarModule } from '../navbar.module'; - -import { SkyDropdownModule } from '../../dropdown'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './navbar.component.visual-fixture.html' -}) -export class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule, - SkyNavbarModule, - SkyDropdownModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/navbar/navbar.component.visual-spec.js b/src/modules/navbar/navbar.component.visual-spec.js deleted file mode 100644 index bbc1da494..000000000 --- a/src/modules/navbar/navbar.component.visual-spec.js +++ /dev/null @@ -1,80 +0,0 @@ -describe('Navbar', function () { - 'use strict'; - - it('should match previous navbar screenshot', function () { - return browser - .setupTest('/navbar.html') - .compareScreenshot({ - screenshotName: 'navbar', - selector: '#screenshot-navbar' - }); - }); - - it('should match previous navbar screenshot when the user mouses over an item', function () { - return browser - .setupTest('/navbar.html') - .moveToObject('#screenshot-navbar .first-item') - .compareScreenshot({ - screenshotName: 'navbar-item-over', - selector: '#screenshot-navbar' - }); - }); - - it('should match previous navbar screenshot when a dropdown is open', function () { - return browser - .setupTest('/navbar.html') - .moveToObject('#screenshot-navbar .sky-dropdown-button') - .compareScreenshot({ - screenshotName: 'navbar-dropdown-open', - selector: '#screenshot-navbar' - }); - }); - - it('should match previous navbar screenshot when the user is over a dropdown item', function () { - return browser - .setupTest('/navbar.html') - .moveToObject('#screenshot-navbar .sky-dropdown-button') - .moveToObject('#screenshot-navbar .sky-dropdown-item:first-child') - .compareScreenshot({ - screenshotName: 'navbar-dropdown-item-over', - selector: '#screenshot-navbar' - }); - }); - - it( - 'should match previous navbar screenshot when an item is active via the item CSS class', - function () { - return browser - .setupTest('/navbar.html') - .compareScreenshot({ - screenshotName: 'navbar-item-active', - selector: '#screenshot-navbar-active-item' - }); - } - ); - - it( - 'should match previous navbar screenshot when an item is active via a child CSS class', - function () { - return browser - .setupTest('/navbar.html') - .compareScreenshot({ - screenshotName: 'navbar-item-active-child', - selector: '#screenshot-navbar-active-child' - }); - } - ); - - it( - 'should match previous navbar screenshot when a dropdown is active', - function () { - return browser - .setupTest('/navbar.html') - .compareScreenshot({ - screenshotName: 'navbar-item-active-child', - selector: '#screenshot-navbar-active-child' - }); - } - ); - -}); diff --git a/src/modules/page-summary/fixtures/page-summary.component.visual-fixture.ts b/src/modules/page-summary/fixtures/page-summary.component.visual-fixture.ts deleted file mode 100644 index 6b4251fc8..000000000 --- a/src/modules/page-summary/fixtures/page-summary.component.visual-fixture.ts +++ /dev/null @@ -1,78 +0,0 @@ -import { - Component, - NgModule -} from '@angular/core'; - -import { BrowserModule } from '@angular/platform-browser'; -import { FormsModule } from '@angular/forms'; - -import { SkyPageSummaryModule } from '../page-summary.module'; - -import { SkyAlertModule } from '../../alert'; - -import { SkyAvatarModule } from '../../avatar'; - -import { SkyLabelModule } from '../../label'; - -import { SkyKeyInfoModule } from '../../key-info'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './page-summary.component.visual-fixture.html' -}) -export class AppComponent { - public name = 'Robert C. Hernandez'; - - public showAlert = false; - - public showImage = false; - - public showTitle = false; - - public showSubtitle = false; - - public showStatus = false; - - public showContent = false; - - public showKeyInfo = false; - - public get itemsToShow(): string { - return this._itemsToShow; - } - - public set itemsToShow(value: string) { - let itemsToShow = value.split(','); - - itemsToShow.forEach((itemToShow) => { - this['show' + itemToShow] = true; - }); - - this._itemsToShow = value; - } - - private _itemsToShow = ''; -} - -@NgModule({ - imports: [ - BrowserModule, - FormsModule, - SkyPageSummaryModule, - SkyAlertModule, - SkyAvatarModule, - SkyLabelModule, - SkyKeyInfoModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/page-summary/page-summary-alert/page-summary-alert.component.ts b/src/modules/page-summary/page-summary-alert/page-summary-alert.component.ts index 27e234126..a17ded0e1 100644 --- a/src/modules/page-summary/page-summary-alert/page-summary-alert.component.ts +++ b/src/modules/page-summary/page-summary-alert/page-summary-alert.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: '../../shared/simple-content.html', styleUrls: ['./page-summary-alert.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummaryAlertComponent { } diff --git a/src/modules/page-summary/page-summary-content/page-summary-content.component.ts b/src/modules/page-summary/page-summary-content/page-summary-content.component.ts index a85e1255f..5a6a715f3 100644 --- a/src/modules/page-summary/page-summary-content/page-summary-content.component.ts +++ b/src/modules/page-summary/page-summary-content/page-summary-content.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: './page-summary-content.component.html', styleUrls: ['./page-summary-content.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummaryContentComponent { } diff --git a/src/modules/page-summary/page-summary-image/page-summary-image.component.ts b/src/modules/page-summary/page-summary-image/page-summary-image.component.ts index 4b8efe81b..e348d8cc3 100644 --- a/src/modules/page-summary/page-summary-image/page-summary-image.component.ts +++ b/src/modules/page-summary/page-summary-image/page-summary-image.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: './page-summary-image.component.html', styleUrls: ['./page-summary-image.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummaryImageComponent { } diff --git a/src/modules/page-summary/page-summary-status/page-summary-status.component.ts b/src/modules/page-summary/page-summary-status/page-summary-status.component.ts index 5e16bcd46..deef9a617 100644 --- a/src/modules/page-summary/page-summary-status/page-summary-status.component.ts +++ b/src/modules/page-summary/page-summary-status/page-summary-status.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: './page-summary-status.component.html', styleUrls: ['./page-summary-status.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummaryStatusComponent { } diff --git a/src/modules/page-summary/page-summary-subtitle/page-summary-subtitle.component.ts b/src/modules/page-summary/page-summary-subtitle/page-summary-subtitle.component.ts index da572f749..e8d40b393 100644 --- a/src/modules/page-summary/page-summary-subtitle/page-summary-subtitle.component.ts +++ b/src/modules/page-summary/page-summary-subtitle/page-summary-subtitle.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: './page-summary-subtitle.component.html', styleUrls: ['./page-summary-subtitle.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummarySubtitleComponent { } diff --git a/src/modules/page-summary/page-summary-title/page-summary-title.component.ts b/src/modules/page-summary/page-summary-title/page-summary-title.component.ts index 774a5dafc..53d4ac0fb 100644 --- a/src/modules/page-summary/page-summary-title/page-summary-title.component.ts +++ b/src/modules/page-summary/page-summary-title/page-summary-title.component.ts @@ -5,4 +5,6 @@ import { Component } from '@angular/core'; templateUrl: './page-summary-title.component.html', styleUrls: ['./page-summary-title.component.scss'] }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyPageSummaryTitleComponent { } diff --git a/src/modules/paging/fixtures/paging.component.visual-fixture.ts b/src/modules/paging/fixtures/paging.component.visual-fixture.ts deleted file mode 100644 index 0a150e1f5..000000000 --- a/src/modules/paging/fixtures/paging.component.visual-fixture.ts +++ /dev/null @@ -1,35 +0,0 @@ -import { - Component, - NgModule -} from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { - SkyPagingModule -} from '../paging.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './paging.component.visual-fixture.html' -}) -export class AppComponent { - -} - -@NgModule({ - imports: [ - BrowserModule, - SkyPagingModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/paging/paging.component.visual-spec.js b/src/modules/paging/paging.component.visual-spec.js deleted file mode 100644 index b73d062f3..000000000 --- a/src/modules/paging/paging.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('paging component', function () { - 'use strict'; - - it('should display first page selected', function () { - return browser - .setupTest('/paging.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'paging_first', - selector: '#screenshot-paging' - }); - }); - - it('should display middle page selected', function () { - return browser - .setupTest('/paging.html') - .pause(1000) - .click('a[sky-cmp-id="next"]') - .pause(1000) - .compareScreenshot({ - screenshotName: 'paging_middle', - selector: '#screenshot-paging' - }); - }); -}); diff --git a/src/modules/radio/fixtures/radio.component.visual-fixture.ts b/src/modules/radio/fixtures/radio.component.visual-fixture.ts deleted file mode 100644 index 0204e3e15..000000000 --- a/src/modules/radio/fixtures/radio.component.visual-fixture.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyRadioModule } from '../radio.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -import { FormsModule } from '@angular/forms'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './radio.component.visual-fixture.html' -}) -export class AppComponent { - public selectedValue = '3'; - public valueGuy = '2'; -} - -@NgModule({ - imports: [ - BrowserModule, - FormsModule, - SkyRadioModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/radio/radio.component.visual-spec.js b/src/modules/radio/radio.component.visual-spec.js deleted file mode 100644 index 7e6db74c5..000000000 --- a/src/modules/radio/radio.component.visual-spec.js +++ /dev/null @@ -1,13 +0,0 @@ -describe('Radio component', function () { - 'use strict'; - - it('should match the radio input', function () { - return browser - .setupTest('/radio.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'radio', - selector: '#screenshot-radio' - }); - }); -}); diff --git a/src/modules/repeater/fixtures/repeater.component.visual-fixture.ts b/src/modules/repeater/fixtures/repeater.component.visual-fixture.ts deleted file mode 100644 index 01b7f6452..000000000 --- a/src/modules/repeater/fixtures/repeater.component.visual-fixture.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyRepeaterModule } from '../repeater.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './repeater.component.visual-fixture.html' -}) -export class AppComponent { } - -@NgModule({ - imports: [ - BrowserModule, - SkyRepeaterModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/repeater/repeater-item-context-menu.component.ts b/src/modules/repeater/repeater-item-context-menu.component.ts index 20f5a6fea..194494c89 100644 --- a/src/modules/repeater/repeater-item-context-menu.component.ts +++ b/src/modules/repeater/repeater-item-context-menu.component.ts @@ -4,4 +4,6 @@ import { Component } from '@angular/core'; selector: 'sky-repeater-item-context-menu', templateUrl: '../shared/simple-content.html' }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyRepeaterItemContextMenuComponent { } diff --git a/src/modules/repeater/repeater.component.visual-spec.js b/src/modules/repeater/repeater.component.visual-spec.js deleted file mode 100644 index d696387b9..000000000 --- a/src/modules/repeater/repeater.component.visual-spec.js +++ /dev/null @@ -1,54 +0,0 @@ -describe('Repeater', function () { - 'use strict'; - - it('should match previous repeater screenshot', function () { - return browser - .setupTest('/repeater.html') - .compareScreenshot({ - screenshotName: 'repeater', - selector: '#screenshot-repeater', - checkAccessibility: true - }); - }); - - it('should match previous repeater screenshot when all are collapsed', function () { - return browser - .setupTest('/repeater.html') - .compareScreenshot({ - screenshotName: 'repeater-collapsed', - selector: '#screenshot-repeater-collapsed', - checkAccessibility: true - }); - }); - - it('should match previous repeater screenshot in single mode', function () { - return browser - .setupTest('/repeater.html') - .compareScreenshot({ - screenshotName: 'repeater-single', - selector: '#screenshot-repeater-single', - checkAccessibility: true - }); - }); - - it('should match previous repeater screenshot in multiple mode', function () { - return browser - .setupTest('/repeater.html') - .compareScreenshot({ - screenshotName: 'repeater-multiple', - selector: '#screenshot-repeater-multiple', - checkAccessibility: true - }); - }); - - it('should match previous repeater screenshot in selectable mode', function () { - return browser - .setupTest('/repeater.html') - .compareScreenshot({ - screenshotName: 'repeater-selectable', - selector: '#screenshot-repeater-selectable', - checkAccessibility: true - }); - }); - -}); diff --git a/src/modules/repeater/repeater.module.ts b/src/modules/repeater/repeater.module.ts index c2be03609..a46440842 100644 --- a/src/modules/repeater/repeater.module.ts +++ b/src/modules/repeater/repeater.module.ts @@ -1,6 +1,8 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; +import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; + import { SkyChevronModule } from '../chevron'; import { SkyLogModule } from '../log'; @@ -25,6 +27,7 @@ import { SkyResourcesModule } from '../resources/resources.module'; SkyRepeaterService ], imports: [ + BrowserAnimationsModule, CommonModule, SkyChevronModule, SkyLogModule, diff --git a/src/modules/search/search.component.spec.ts b/src/modules/search/search.component.spec.ts index 597b3f0f7..7babfefca 100644 --- a/src/modules/search/search.component.spec.ts +++ b/src/modules/search/search.component.spec.ts @@ -36,6 +36,7 @@ import { SkyMediaQueryService, SkyMediaBreakpoints } from '../media-queries'; +import { NoopAnimationsModule } from '@angular/platform-browser/animations'; describe('Search component', () => { let fixture: ComponentFixture; @@ -53,7 +54,8 @@ describe('Search component', () => { SearchTestComponent ], imports: [ - SkySearchModule + SkySearchModule, + NoopAnimationsModule ], providers: [ {provide: SkyMediaQueryService, useValue: mockMediaQueryService} @@ -201,7 +203,7 @@ describe('Search component', () => { fixture.detectChanges(); }); - it('should apply search text on enter press', () => { + it('should apply search text on enter press', () => { setInput('my search text'); let inputEl = element.query(By.css('input')); diff --git a/src/modules/search/search.component.ts b/src/modules/search/search.component.ts index 11a360e91..564ee98c4 100644 --- a/src/modules/search/search.component.ts +++ b/src/modules/search/search.component.ts @@ -1,10 +1,5 @@ import { Component, - trigger, - state, - style, - transition, - animate, OnInit, OnDestroy, AnimationTransitionEvent, @@ -32,6 +27,14 @@ import { import { Subscription } from 'rxjs/Subscription'; +import { + style, + state, + trigger, + transition, + animate +} from '@angular/animations'; + const INPUT_SHOWN_STATE: string = 'inputShown'; const INPUT_HIDDEN_STATE: string = 'inputHidden'; const EXPAND_MODE_RESPONSIVE: string = 'responsive'; @@ -93,7 +96,7 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { this._placeholderText = value; } - public inputAnimate: string = INPUT_SHOWN_STATE; + public inputAnimate: string = INPUT_SHOWN_STATE; public breakpointSubscription: Subscription; public searchButtonShown: boolean = false; public mobileSearchShown: boolean = false; @@ -116,6 +119,7 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { this.breakpointSubscription = this.mediaQueryService.subscribe( (args: SkyMediaBreakpoints) => { this.mediaQueryCallback(args); + this.changeRef.detectChanges(); } ); } @@ -137,6 +141,7 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { this.isFullWidth = false; break; } + } if (this.searchBindingChanged(changes)) { @@ -145,6 +150,7 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { this.inputAnimate = INPUT_SHOWN_STATE; } } + this.changeRef.detectChanges(); } public inputFocused(isFocused: boolean) { @@ -200,7 +206,9 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { && this.mediaQueryService.current === SkyMediaBreakpoints.xs) { this.mobileSearchShown = true; this.searchButtonShown = false; + } + } } @@ -224,7 +232,6 @@ export class SkySearchComponent implements OnDestroy, OnInit, OnChanges { this.breakpointSubscription.unsubscribe(); } } - private searchBindingChanged(changes: SimpleChanges) { return changes['searchText'] && changes['searchText'].previousValue !== changes['searchText'].currentValue; diff --git a/src/modules/search/search.component.visual-spec.js b/src/modules/search/search.component.visual-spec.js deleted file mode 100644 index d587f074d..000000000 --- a/src/modules/search/search.component.visual-spec.js +++ /dev/null @@ -1,88 +0,0 @@ -describe('search component', function () { - 'use strict'; - - it('should match the baseline search screenshot', function () { - return browser - .setupTest('/search.html') - .pause(2000) - .compareScreenshot({ - screenshotName: 'search', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - }); - - /*it('should match the baseline search screenshot when the input is focused', function () { - return browser - .setupTest('/search.html') - .pause(1000) - .focusElement('.sky-search-input') - .compareScreenshot({ - screenshotName: 'search_focus', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - });*/ - - it('should match the baseline search screenshot on small screens', function () { - return browser - .setupTest('/search.html', 480) - .pause(1000) - .compareScreenshot({ - screenshotName: 'search_small', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - }); - - it('should match the baseline search screenshot on small screens when dismissable input is shown', - function () { - return browser - .setupTest('/search.html', 480) - .pause(1000) - .click('.sky-search-btn-open') - .pause(1000) - .compareScreenshot({ - screenshotName: 'search_small_dismissable', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - }); - - it('should match the baseline search screenshot on small screens when search is applied', - function () { - return browser - .setupTest('/search.html', 480) - .pause(1000) - .click('.sky-search-btn-open') - .pause(1000) - .setValue('.sky-search-input', 'Value') - .click('.sky-search-btn-apply') - .pause(1000) - .compareScreenshot({ - screenshotName: 'search_small_dismissable_applied', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - }); - - it('should match the baseline screenshot on small screens when search is applied and dismissed', - function () { - return browser - .setupTest('/search.html', 480) - .pause(1000) - .click('.sky-search-btn-open') - .pause(1000) - .setValue('.sky-search-input', 'Value') - .click('.sky-search-btn-apply') - .pause(1000) - .click('.sky-search-btn-dismiss') - .pause(1000) - .compareScreenshot({ - screenshotName: 'search_small_applied', - selector: '#screenshot-search-full', - checkAccessibility: true - }); - }); - -}); diff --git a/src/modules/search/search.module.ts b/src/modules/search/search.module.ts index 68128d6b6..c93ee65c2 100644 --- a/src/modules/search/search.module.ts +++ b/src/modules/search/search.module.ts @@ -2,6 +2,8 @@ import { NgModule } from '@angular/core'; import { CommonModule } from '@angular/common'; import { FormsModule } from '@angular/forms'; +import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; + import { SkySearchComponent } from './search.component'; import { SkyMediaQueryModule } from '../media-queries'; @@ -12,6 +14,7 @@ import { SkyResourcesModule } from '../resources'; SkySearchComponent ], imports: [ + BrowserAnimationsModule, CommonModule, SkyResourcesModule, SkyMediaQueryModule, diff --git a/src/modules/sort/fixtures/sort.component.fixture.ts b/src/modules/sort/fixtures/sort.component.fixture.ts index b0d4b0f11..8946be857 100644 --- a/src/modules/sort/fixtures/sort.component.fixture.ts +++ b/src/modules/sort/fixtures/sort.component.fixture.ts @@ -1,11 +1,11 @@ -import { Component } from '@angular/core'; +import { Component, OnInit } from '@angular/core'; @Component({ selector: 'sky-test-cmp', templateUrl: './sort.component.fixture.html' }) -export class SortTestComponent { - public initialState = 3; +export class SortTestComponent implements OnInit { + public initialState: number; public sortOptions = [ { id: 1, @@ -47,6 +47,10 @@ export class SortTestComponent { public sortedItem: any; + public ngOnInit() { + this.initialState = 3; + } + public sortItems(item: any) { this.sortedItem = item; } diff --git a/src/modules/sort/sort-item.component.ts b/src/modules/sort/sort-item.component.ts index 71c5da917..fc2be4a08 100644 --- a/src/modules/sort/sort-item.component.ts +++ b/src/modules/sort/sort-item.component.ts @@ -7,7 +7,8 @@ import { SimpleChanges, OnChanges, ChangeDetectionStrategy, - OnDestroy + OnDestroy, + ChangeDetectorRef } from '@angular/core'; import { SkySortService } from './sort.service'; @@ -38,13 +39,15 @@ export class SkySortItemComponent implements OnInit, OnChanges, OnDestroy { private sortItemId: string; - constructor(private sortService: SkySortService) {} + constructor(private sortService: SkySortService, private detector: ChangeDetectorRef) {} public ngOnInit() { + sortItemIdNumber++; this.sortItemId = SORT_ITEM_ID_PREFIX + sortItemIdNumber.toString(); this.subscription = this.sortService.selectedItem.subscribe((itemId: string) => { this.isSelected.next(itemId === this.sortItemId); + this.detector.detectChanges(); }); if (this.active) { @@ -56,7 +59,6 @@ export class SkySortItemComponent implements OnInit, OnChanges, OnDestroy { if (changes && changes['active'] && changes['active'].currentValue && changes['active'].currentValue !== changes['active'].previousValue) { - this.sortService.selectItem(this.sortItemId); } } diff --git a/src/modules/sort/sort.component.spec.ts b/src/modules/sort/sort.component.spec.ts index b0968ae65..f111025ff 100644 --- a/src/modules/sort/sort.component.spec.ts +++ b/src/modules/sort/sort.component.spec.ts @@ -86,7 +86,6 @@ describe('Sort component', () => { it('can set active input programmatically', () => { component.initialState = 4; fixture.detectChanges(); - let itemsEl = getSortItems(); expect(itemsEl.item(3)).toHaveCssClass('sky-sort-item-selected'); }); diff --git a/src/modules/sort/sort.component.visual-spec.js b/src/modules/sort/sort.component.visual-spec.js deleted file mode 100644 index e8e43f077..000000000 --- a/src/modules/sort/sort.component.visual-spec.js +++ /dev/null @@ -1,28 +0,0 @@ -describe('Sort component', function () { - 'use strict'; - - it('should match the baseline sort screenshot', function () { - return browser - .setupTest('/sort.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'sort', - selector: '#screenshot-sort-full', - checkAccessibility: true - }); - }); - - it('should match the baseline sort screenshot when dropdown is open', function () { - return browser - .setupTest('/sort.html') - .pause(1000) - .click('button') - .pause(1000) - .compareScreenshot({ - screenshotName: 'sort_open', - selector: '#screenshot-sort-full', - checkAccessibility: true - }); - }); - -}); diff --git a/src/modules/tabs/fixtures/tabset.component.visual-fixture.ts b/src/modules/tabs/fixtures/tabset.component.visual-fixture.ts deleted file mode 100644 index eddfd950f..000000000 --- a/src/modules/tabs/fixtures/tabset.component.visual-fixture.ts +++ /dev/null @@ -1,60 +0,0 @@ -import { ChangeDetectionStrategy, Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyTabsModule } from '../tabs.module'; - -import { SkyCheckboxModule } from '../../checkbox'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -import { FormsModule } from '@angular/forms'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './tabset.component.visual-fixture.html', - changeDetection: ChangeDetectionStrategy.OnPush -}) -export class AppComponent { - - public showWizard = false; - - public requiredValue1: string; - - public requiredValue2: boolean; - - public newTabClick() { } - - public openTabClick() { } - - public closeTab() { } - - public get step2Disabled(): boolean { - return !this.requiredValue1; - } - - public get step3Disabled(): boolean { - return this.step2Disabled || !this.requiredValue2; - } - - public validateStep1() { - return true; - } -} - -@NgModule({ - imports: [ - BrowserModule, - SkyCheckboxModule, - SkyTabsModule, - FormsModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/tabs/tab-button.component.html b/src/modules/tabs/tab-button.component.html index 53fbda618..5cc52dfb6 100644 --- a/src/modules/tabs/tab-button.component.html +++ b/src/modules/tabs/tab-button.component.html @@ -6,6 +6,8 @@ 'sky-btn-tab-disabled': disabled, 'sky-tab-btn-closeable': allowClose }" + tabindex="0" + (keydown)="keyDownFunction($event)" (click)="doTabClick()" role="tab" [attr.aria-selected]="active" diff --git a/src/modules/tabs/tab-button.component.ts b/src/modules/tabs/tab-button.component.ts index 2fd4a1cb0..4f5305721 100644 --- a/src/modules/tabs/tab-button.component.ts +++ b/src/modules/tabs/tab-button.component.ts @@ -44,4 +44,10 @@ export class SkyTabButtonComponent { public doCloseClick() { this.closeClick.emit(undefined); } + + public keyDownFunction(event: any) { + if (event.keyCode === 13) { + this.doTabClick(); + } + } } diff --git a/src/modules/tabs/tab-dropdown.component.ts b/src/modules/tabs/tab-dropdown.component.ts index 5729d3a4b..3bb5242b0 100644 --- a/src/modules/tabs/tab-dropdown.component.ts +++ b/src/modules/tabs/tab-dropdown.component.ts @@ -32,6 +32,9 @@ export class SkyTabDropdownComponent { if (activeTab.length > 0) { return activeTab[0].tabHeading; } + /* istanbul ignore next */ + /* sanity check */ + return ''; } public selectTab(tab: SkyTabComponent) { diff --git a/src/modules/tabs/tabset.component.spec.ts b/src/modules/tabs/tabset.component.spec.ts index 05fe85a1d..b9935ba64 100644 --- a/src/modules/tabs/tabset.component.spec.ts +++ b/src/modules/tabs/tabset.component.spec.ts @@ -16,6 +16,12 @@ import { TestUtility } from '../testing/testutility'; import { expect } from '../testing'; +import { + DebugElement +} from '@angular/core'; + +import { By } from '@angular/platform-browser'; + describe('Tabset component', () => { beforeEach(() => { TestBed.configureTestingModule({ @@ -656,4 +662,41 @@ describe('Tabset component', () => { }); }); }); + + describe('keyboard accessibility', () => { + let debugElement: DebugElement; + let cmp: TabsetTestComponent; + let fixture: ComponentFixture; + + beforeEach(() => { + TestBed.configureTestingModule({ + imports: [ + SkyTabsFixturesModule + ] + }); + fixture = TestBed.createComponent(TabsetTestComponent); + debugElement = fixture.debugElement; + cmp = fixture.componentInstance as TabsetTestComponent; + }); + + it('should have tabindex of 0', () => { + fixture.detectChanges(); + expect(debugElement.query(By.css('.sky-btn-tab')).attributes['tabindex']).toBe('0'); + }); + + it('should emit a click event on enter press', () => { + fixture.detectChanges(); + fixture.detectChanges(); + let el = debugElement.queryAll(By.css('.sky-btn-tab'))[1]; + + el.triggerEventHandler('keydown', { keyCode: 15}); + fixture.detectChanges(); + validateTabSelected(fixture.nativeElement, 0); + + el.triggerEventHandler('keydown', { keyCode: 13}); + fixture.detectChanges(); + validateTabSelected(fixture.nativeElement, 1); + } + ); + }); }); diff --git a/src/modules/tabs/tabset.component.visual-spec.js b/src/modules/tabs/tabset.component.visual-spec.js deleted file mode 100644 index a27178bb3..000000000 --- a/src/modules/tabs/tabset.component.visual-spec.js +++ /dev/null @@ -1,55 +0,0 @@ -describe('TabSet', function () { - 'use strict'; - - it('should match previous tabset screenshot', function () { - return browser - .setupTest('/tabs.html') - .compareScreenshot({ - screenshotName: 'tabset', - selector: '#screenshot-tabset' - }); - }); - - it('should match the tabset screenshot with wizard styling', function () { - return browser - .setupTest('/tabs.html') - .click('.sky-test-show-wizard') - .compareScreenshot({ - screenshotName: 'tabset-wizard', - selector: '#screenshot-tabset' - }); - }); - - it('should match previous mobile tabset screenshot', function () { - return browser - .setupTest('/tabs.html', 480) - .compareScreenshot({ - screenshotName: 'tabset-collapsed', - selector: '#screenshot-tabset' - }); - }); - - it('should match previous mobile dropdown tabset screenshot', function () { - return browser - .setupTest('/tabs.html', 480) - .waitForVisible('#screenshot-tabset button.sky-dropdown-button-type-tab') - .click('#screenshot-tabset button.sky-dropdown-button-type-tab') - .moveCursorOffScreen() - .compareScreenshot({ - screenshotName: 'tabset-collapsed-dropdown', - selector: '#screenshot-tabset' - }); - }); - - it('should match previous mobile dropdown tabset screenshot with long tab', function () { - return browser - .setupTest('/tabs.html', 480) - .waitForVisible('#screenshot-tabset-long button.sky-dropdown-button-type-tab') - .moveCursorOffScreen() - .compareScreenshot({ - screenshotName: 'tabset_collapsed_dropdown_long', - selector: '#screenshot-tabset-long' - }); - }); - -}); diff --git a/src/modules/tabs/tabset.service.ts b/src/modules/tabs/tabset.service.ts index b0f1fb444..985896948 100644 --- a/src/modules/tabs/tabset.service.ts +++ b/src/modules/tabs/tabset.service.ts @@ -94,5 +94,7 @@ export class SkyTabsetService { return existingTab; } } + + return undefined; } } diff --git a/src/modules/text-expand-repeater/fixtures/text-expand-repeater.component.visual-fixture.ts b/src/modules/text-expand-repeater/fixtures/text-expand-repeater.component.visual-fixture.ts deleted file mode 100644 index d0b93e122..000000000 --- a/src/modules/text-expand-repeater/fixtures/text-expand-repeater.component.visual-fixture.ts +++ /dev/null @@ -1,28 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyTextExpandRepeaterModule } from '../text-expand-repeater.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './text-expand-repeater.component.visual-fixture.html' -}) -class AppComponent {} - -@NgModule({ - imports: [ - BrowserModule, - SkyTextExpandRepeaterModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/text-expand-repeater/text-expand-repeater.component.visual-spec.js b/src/modules/text-expand-repeater/text-expand-repeater.component.visual-spec.js deleted file mode 100644 index 3aa62a213..000000000 --- a/src/modules/text-expand-repeater/text-expand-repeater.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('TextExpandRepeater', function () { - 'use strict'; - - it('should match previous text expand repeater when not expanded', function () { - return browser - .setupTest('/text-expand-repeater.html') - .compareScreenshot({ - checkAccessibility: true, - screenshotName: 'text-expand-repeater-not-expanded', - selector: '#text-expand-repeater' - }); - }); - - it('should match the previous text expand repeater when expanded', function () { - return browser - .setupTest('/text-expand-repeater.html') - .click('.sky-text-expand-repeater-see-more') - .compareScreenshot({ - checkAccessibility: true, - screenshotName: 'text-expand-repeater-expanded', - selector: '#text-expand-repeater' - }); - }); - -}); diff --git a/src/modules/text-expand/text-expand-modal-context.ts b/src/modules/text-expand/text-expand-modal-context.ts index e8274d7fd..df810f960 100644 --- a/src/modules/text-expand/text-expand-modal-context.ts +++ b/src/modules/text-expand/text-expand-modal-context.ts @@ -1,3 +1,5 @@ +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyTextExpandModalContext { public header: string; public text: string; diff --git a/src/modules/text-expand/text-expand.component.ts b/src/modules/text-expand/text-expand.component.ts index b8d323433..d7a26694b 100644 --- a/src/modules/text-expand/text-expand.component.ts +++ b/src/modules/text-expand/text-expand.component.ts @@ -203,5 +203,4 @@ export class SkyTextExpandComponent implements AfterContentInit { }, 500); }, 10); } - } diff --git a/src/modules/text-expand/text-expand.component.visual-spec.js b/src/modules/text-expand/text-expand.component.visual-spec.js deleted file mode 100644 index 3369104ca..000000000 --- a/src/modules/text-expand/text-expand.component.visual-spec.js +++ /dev/null @@ -1,33 +0,0 @@ -describe('TextExpand', function () { - 'use strict'; - - it('should match previous text expands when not expanded', function () { - return browser - .setupTest('/text-expand.html') - .compareScreenshot({ - screenshotName: 'text-expand-not-expanded', - selector: '#text-expands' - }); - }); - - it('should match the previous normal text expand when expanded', function () { - return browser - .setupTest('/text-expand.html') - .click('#normal-text-expand .sky-text-expand-see-more') - .compareScreenshot({ - screenshotName: 'text-expand-normal-expanded', - selector: '#normal-text-expand' - }); - }); - - it('should match previous modal text expand when expanded', function () { - return browser - .setupTest('/text-expand.html') - .click('#modal-text-expand .sky-text-expand-see-more') - .compareScreenshot({ - screenshotName: 'text-expand-modal-expanded', - selector: '.sky-modal' - }); - }); - -}); diff --git a/src/modules/text-highlight/fixtures/text-highlight.component.fixture.html b/src/modules/text-highlight/fixtures/text-highlight.component.fixture.html new file mode 100644 index 000000000..29eb67e27 --- /dev/null +++ b/src/modules/text-highlight/fixtures/text-highlight.component.fixture.html @@ -0,0 +1,8 @@ + + + +
    Here is some test text. +
    + Here is additional text that was previously hidden. +
    +
    diff --git a/src/modules/text-highlight/fixtures/text-highlight.component.fixture.ts b/src/modules/text-highlight/fixtures/text-highlight.component.fixture.ts new file mode 100644 index 000000000..e102ef3de --- /dev/null +++ b/src/modules/text-highlight/fixtures/text-highlight.component.fixture.ts @@ -0,0 +1,11 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'sky-text-highlight-component', + templateUrl: 'text-highlight.component.fixture.html' +}) + +export class SkyTextHighlightTestComponent { + public searchTerm: string; + public showAdditionalContent: boolean = false; +} diff --git a/src/modules/text-highlight/index.ts b/src/modules/text-highlight/index.ts new file mode 100644 index 000000000..c0c842957 --- /dev/null +++ b/src/modules/text-highlight/index.ts @@ -0,0 +1,2 @@ +export { SkyTextHighlightModule } from './text-highlight.module'; +export { SkyTextHighlightDirective } from './text-highlight.directive'; diff --git a/src/modules/text-highlight/text-highlight.directive.spec.ts b/src/modules/text-highlight/text-highlight.directive.spec.ts new file mode 100644 index 000000000..b5409ce05 --- /dev/null +++ b/src/modules/text-highlight/text-highlight.directive.spec.ts @@ -0,0 +1,217 @@ +import { + TestBed, + ComponentFixture +} from '@angular/core/testing'; + +import { FormsModule } from '@angular/forms'; + +import { SkyTextHighlightTestComponent } from './fixtures/text-highlight.component.fixture'; +import { SkyCheckboxModule } from '../checkbox/checkbox.module'; +import { SkyTextHighlightModule } from './text-highlight.module'; +import { MutationObserverService } from '../mutation/mutation-observer-service'; + +function updateInputText(fixture: ComponentFixture, text: string) { + let params = { + bubbles: false, + cancelable: false + }; + + let inputEvent = document.createEvent('Event'); + inputEvent.initEvent('input', params.bubbles, params.cancelable); + + const inputEl = fixture.nativeElement.querySelector('.sky-input-search-term') as HTMLInputElement; + inputEl.value = text; + inputEl.dispatchEvent(inputEvent); + fixture.detectChanges(); +} + +const additionalTextHidden = ` + `; + +const additionalTextVisible = ` + `; + +function getHtmlOutput(text: string) { + return `${text}${additionalTextHidden}`; +} + +function getHtmlOutputAdditionalText(text: string, additionalText: string) { + return `${text}${additionalTextVisible}
    + ${additionalText} +
    `; +} + +describe('Text Highlight', () => { + + let fixture: ComponentFixture; + let component: SkyTextHighlightTestComponent; + let nativeElement: HTMLElement; + let callbacks: any[]; + + beforeEach(() => { + TestBed.configureTestingModule({ + declarations: [ + SkyTextHighlightTestComponent + ], + imports: [ + SkyCheckboxModule, + SkyTextHighlightModule, + FormsModule + ], + providers: [{ + provide: MutationObserverService, + useValue: { + create: function(callback: Function) { + callbacks.push(callback); + + return { + observe: () => {}, + disconnect: () => {} + }; + } + } + }] + }); + + callbacks = []; + fixture = TestBed.createComponent(SkyTextHighlightTestComponent); + nativeElement = fixture.nativeElement as HTMLElement; + component = fixture.componentInstance; + fixture.detectChanges(); + }); + + it('should not highlight any text when search term is blank', () => { + const containerEl = nativeElement.querySelector('.sky-test-div-container'); + const expectedHtml = getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + }); + + it('should highlight search term', () => { + updateInputText(fixture, 'text'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtml = + getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + }); + + it('should highlight case insensitive search term', () => { + updateInputText(fixture, 'here'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtml = + getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + }); + + it('should highlight search term in nested component', () => { + component.showAdditionalContent = true; + fixture.detectChanges(); + + updateInputText(fixture, 'here'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const text = 'Here is some test text.'; + // tslint:disable-next-line:max-line-length + const additional = 'Here is additional text that was previously hidden.'; + const expectedHtml = getHtmlOutputAdditionalText(text, additional); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + }); + + it('changed search term should highlight new term and old term should not highlight', () => { + updateInputText(fixture, 'some'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtml = + getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + + updateInputText(fixture, 'Here'); + + const containerElChanged = + nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtmlChanged = + getHtmlOutput('Here is some test text.'); + + expect(containerElChanged.innerHTML.trim()).toBe(expectedHtmlChanged); + }); + + it('highlight search term of html that was previously hidden', () => { + component.showAdditionalContent = false; + fixture.detectChanges(); + + updateInputText(fixture, 'is'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtml = + getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + + // check box to show extra content + const checkboxEl = + fixture.nativeElement.querySelector('.sky-test-checkbox') as HTMLInputElement; + + checkboxEl.click(); + fixture.detectChanges(); + + // mock the mutation observer callback on DOM change + callbacks[0](undefined); + + fixture.detectChanges(); + + const containerElUpdated = + nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + + const text = 'Here is some test text.'; + // tslint:disable-next-line:max-line-length + const additional = 'Here is additional text that was previously hidden.'; + const expectedHtmlChanged = getHtmlOutputAdditionalText(text, additional); + + expect(containerElUpdated.innerHTML.trim()).toBe(expectedHtmlChanged); + }); + + it('highlight hidden search term where only highlighted term was hidden', () => { + component.showAdditionalContent = false; + fixture.detectChanges(); + + updateInputText(fixture, 'additional'); + + const containerEl = nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + const expectedHtml = + getHtmlOutput('Here is some test text.'); + + expect(containerEl.innerHTML.trim()).toBe(expectedHtml); + + // check box to show extra content + const checkboxEl = + fixture.nativeElement.querySelector('.sky-test-checkbox') as HTMLInputElement; + + checkboxEl.click(); + fixture.detectChanges(); + + // mock the mutation observer callback on DOM change + callbacks[0](undefined); + + fixture.detectChanges(); + + const containerElUpdated = + nativeElement.querySelector('.sky-test-div-container') as HTMLElement; + + const text = 'Here is some test text.'; + // tslint:disable-next-line:max-line-length + const additional = 'Here is additional text that was previously hidden.'; + const expectedHtmlChanged = getHtmlOutputAdditionalText(text, additional); + + expect(containerElUpdated.innerHTML.trim()).toBe(expectedHtmlChanged); + }); +}); diff --git a/src/modules/text-highlight/text-highlight.directive.ts b/src/modules/text-highlight/text-highlight.directive.ts new file mode 100644 index 000000000..5c80394c9 --- /dev/null +++ b/src/modules/text-highlight/text-highlight.directive.ts @@ -0,0 +1,140 @@ +import { + Directive, + SimpleChanges, + Input, + AfterViewInit, + OnChanges, + ElementRef, + OnDestroy +} from '@angular/core'; + +import { MutationObserverService } from '../mutation/mutation-observer-service'; + +const className = 'sky-highlight-mark'; + +@Directive({ + selector: '[skyHighlight]' +}) +export class SkyTextHighlightDirective implements OnChanges, AfterViewInit, OnDestroy { + + @Input() + public skyHighlight: string = undefined; + + private existingHighlight = false; + private observer: MutationObserver; + + private static getRegexMatch(node: HTMLElement, searchText: string): RegExpExecArray { + const text = node.nodeValue; + const searchRegex = new RegExp(searchText, 'gi'); + + return searchRegex.exec(text); + } + + private static markNode(node: any, searchText: string) { + const regexMatch = SkyTextHighlightDirective.getRegexMatch(node, searchText); + + // found match + if (regexMatch && regexMatch.length > 0) { + + // split apart text node with mark tags in the middle on the search term + const matchIndex = regexMatch.index; + + const middle = node.splitText(matchIndex); + middle.splitText(searchText.length); + const middleClone = middle.cloneNode(true); + + const markNode = document.createElement('mark'); + markNode.className = className; + markNode.appendChild(middleClone); + middle.parentNode.replaceChild(markNode, middle); + + return 1; + } else { + return 0; + } + } + + private static markTextNodes(node: HTMLElement, searchText: string) { + if (node.nodeType === 3) { + return SkyTextHighlightDirective.markNode(node, searchText); + + } else if (node.nodeType === 1 && node.childNodes) { + for (let i = 0; i < node.childNodes.length; i++) { + let childNode = node.childNodes[i] as HTMLElement; + i += SkyTextHighlightDirective.markTextNodes(childNode, searchText); + } + } + + return 0; + } + + private static removeHighlight(el: ElementRef) { + const matchedElements = + el.nativeElement.querySelectorAll(`mark.${className}`) as NodeList; + + /* istanbul ignore else */ + /* sanity check */ + if (matchedElements) { + for (let i = 0; i < matchedElements.length; i++) { + const node = matchedElements[i]; + const parentNode = node.parentNode; + + parentNode.replaceChild(node.firstChild, node); + parentNode.normalize(); + } + } + } + + constructor(private el: ElementRef, private observerService: MutationObserverService) { } + + public ngOnChanges(changes: SimpleChanges): void { + this.highlight(); + } + + public ngAfterViewInit(): void { + let me = this; + + this.observer = this.observerService.create((mutations: MutationRecord[]) => { + me.highlight(); + }); + + this.observeDom(); + } + + public ngOnDestroy(): void { + this.observer.disconnect(); + } + + private readyForHighlight(searchText: string): boolean { + return searchText && this.el.nativeElement; + } + + private highlight(): void { + if (this.observer) { + this.observer.disconnect(); + } + + const searchText = this.skyHighlight; + + if (this.existingHighlight) { + SkyTextHighlightDirective.removeHighlight(this.el); + } + + if (this.readyForHighlight(searchText)) { + const node: HTMLElement = this.el.nativeElement; + + // mark all matched text in the DOM + SkyTextHighlightDirective.markTextNodes(node, searchText); + this.existingHighlight = true; + } + + this.observeDom(); + } + + private observeDom() { + if (this.observer) { + const config = { attributes: true, childList: true, characterData: true }; + this.observer.observe(this.el.nativeElement, config); + } + } +} diff --git a/src/modules/text-highlight/text-highlight.module.ts b/src/modules/text-highlight/text-highlight.module.ts new file mode 100644 index 000000000..dd011696d --- /dev/null +++ b/src/modules/text-highlight/text-highlight.module.ts @@ -0,0 +1,16 @@ +import { NgModule } from '@angular/core'; +import { SkyTextHighlightDirective } from './text-highlight.directive'; +import { MutationObserverService } from '../mutation/mutation-observer-service'; + +@NgModule({ + declarations: [ + SkyTextHighlightDirective + ], + exports: [ + SkyTextHighlightDirective + ], + providers: [ + MutationObserverService + ] +}) +export class SkyTextHighlightModule { } diff --git a/src/modules/tiles/tile.component.visual-spec.js b/src/modules/tiles/tile.component.visual-spec.js deleted file mode 100644 index 0925545e5..000000000 --- a/src/modules/tiles/tile.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('Tile', function () { - 'use strict'; - - it('should match previous tile screenshot', function () { - return browser - .setupTest('/tiles.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'tile', - selector: '#screenshot-tiles', - checkAccessibility: true - }); - }); - - it('should match previous tile screenshot on small screens', function () { - return browser - .setupTest('/tiles.html', 480) - .pause(1000) - .compareScreenshot({ - screenshotName: 'tile_small', - selector: '#screenshot-tiles', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/tiles/tile/tile-summary.component.ts b/src/modules/tiles/tile/tile-summary.component.ts index 49c3819b7..076eedf5b 100644 --- a/src/modules/tiles/tile/tile-summary.component.ts +++ b/src/modules/tiles/tile/tile-summary.component.ts @@ -4,4 +4,6 @@ import { Component } from '@angular/core'; selector: 'sky-tile-summary', templateUrl: '../../shared/simple-content.html' }) +/* istanbul ignore next */ +/* Code coverage having problems with no statements in classes */ export class SkyTileSummaryComponent { } diff --git a/src/modules/tiles/tile/tile.component.ts b/src/modules/tiles/tile/tile.component.ts index 431b243d2..1c1f59c16 100644 --- a/src/modules/tiles/tile/tile.component.ts +++ b/src/modules/tiles/tile/tile.component.ts @@ -13,7 +13,7 @@ import { transition } from '@angular/core'; -import { SkyTileDashboardService } from './../tile-dashboard'; +import { SkyTileDashboardService } from '../tile-dashboard/tile-dashboard.service'; @Component({ selector: 'sky-tile', @@ -77,8 +77,8 @@ export class SkyTileComponent implements AfterViewInit { } constructor( - @Optional() private dashboardService: SkyTileDashboardService, - public elementRef: ElementRef + public elementRef: ElementRef, + @Optional() private dashboardService: SkyTileDashboardService ) { this.isInDashboardColumn = !!dashboardService; } diff --git a/src/modules/tiles/tiles.module.ts b/src/modules/tiles/tiles.module.ts index 163a1242a..7f49580c0 100644 --- a/src/modules/tiles/tiles.module.ts +++ b/src/modules/tiles/tiles.module.ts @@ -1,11 +1,16 @@ import { NgModule } from '@angular/core'; +import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; + import { SkyTileModule } from './tile'; import { SkyTileContentModule } from './tile-content'; import { SkyTileDashboardModule } from './tile-dashboard'; import { SkyTileDashboardColumnModule } from './tile-dashboard-column'; @NgModule({ + imports: [ + BrowserAnimationsModule + ], exports: [ SkyTileContentModule, SkyTileModule, diff --git a/src/modules/timepicker/timepicker.component.ts b/src/modules/timepicker/timepicker.component.ts index 46524524c..49aad1479 100644 --- a/src/modules/timepicker/timepicker.component.ts +++ b/src/modules/timepicker/timepicker.component.ts @@ -59,6 +59,9 @@ export class SkyTimepickerComponent implements OnInit { if (format === 'hh') { return ++i; } /* istanbul ignore else */ if (format === 'HH') { return i; } + /* istanbul ignore next */ + /* sanity check */ + return 0; }), 'minutes': Array.apply(undefined, Array(m)) .map(function (x: number, i: number) { @@ -76,9 +79,10 @@ export class SkyTimepickerComponent implements OnInit { public set selectedTime(newTime: SkyTimepickerTimeOutput) { if (typeof newTime !== 'undefined') { + /* sanity check */ /* istanbul ignore else */ if (newTime.local !== 'Invalid date') { - this.activeTime = newTime.ios8601; + this.activeTime = newTime.iso8601; } } } @@ -96,7 +100,7 @@ export class SkyTimepickerComponent implements OnInit { minute: moment(this.activeTime).minute(), meridie: moment(this.activeTime).format('A'), timezone: moment(this.activeTime).format('Z'), - ios8601: this.activeTime, + iso8601: this.activeTime, local: moment(this.activeTime).format(this.localeFormat), customFormat: (typeof this.returnFormat !== 'undefined') ? this.returnFormat : this.localeFormat @@ -175,5 +179,6 @@ export class SkyTimepickerComponent implements OnInit { if (this.activeTime) { return moment(this.activeTime).format('A'); } + return ''; } } diff --git a/src/modules/timepicker/timepicker.directive.ts b/src/modules/timepicker/timepicker.directive.ts index 19839a0bd..6551b034b 100644 --- a/src/modules/timepicker/timepicker.directive.ts +++ b/src/modules/timepicker/timepicker.directive.ts @@ -108,7 +108,7 @@ export class SkyTimepickerInputDirective implements public validate(control: AbstractControl): { [key: string]: any } { let value = control.value; if (!value) { - return; + return undefined; } /* istanbul ignore next */ @@ -119,6 +119,8 @@ export class SkyTimepickerInputDirective implements } }; } + + return undefined; } private writeModelValue(model: SkyTimepickerTimeOutput) { let setElementValue: string; @@ -151,7 +153,7 @@ export class SkyTimepickerInputDirective implements 'minute': moment(time, currentFormat).minute(), 'meridie': moment(time, currentFormat).format('A'), 'timezone': moment(time, currentFormat).format('Z'), - 'ios8601': moment(time, currentFormat).format(), + 'iso8601': moment(time, currentFormat).format(), 'local': moment(time, currentFormat).format(currentFormat), 'customFormat': this.returnFormat }; diff --git a/src/modules/timepicker/timepicker.interface.ts b/src/modules/timepicker/timepicker.interface.ts index 9ec29d4c3..418438ff0 100644 --- a/src/modules/timepicker/timepicker.interface.ts +++ b/src/modules/timepicker/timepicker.interface.ts @@ -3,7 +3,7 @@ export interface SkyTimepickerTimeOutput { minute: number; meridie: string; timezone: number; - ios8601: Date; + iso8601: Date; local: string; customFormat: string; } diff --git a/src/modules/toolbar/fixtures/toolbar.component.visual-fixture.ts b/src/modules/toolbar/fixtures/toolbar.component.visual-fixture.ts deleted file mode 100644 index 269cfc141..000000000 --- a/src/modules/toolbar/fixtures/toolbar.component.visual-fixture.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyToolbarModule } from '../toolbar.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './toolbar.component.visual-fixture.html' -}) -class AppComponent { -} - -@NgModule({ - imports: [ - BrowserModule, - SkyToolbarModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/toolbar/toolbar.component.visual-spec.js b/src/modules/toolbar/toolbar.component.visual-spec.js deleted file mode 100644 index f8ffa8346..000000000 --- a/src/modules/toolbar/toolbar.component.visual-spec.js +++ /dev/null @@ -1,25 +0,0 @@ -describe('Toolbar', function () { - 'use strict'; - - it('should match previous toolbar screenshot', function () { - return browser - .setupTest('/toolbar.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'toolbar', - selector: '#screenshot-toolbar', - checkAccessibility: true - }); - }); - - it('should match previous toolbar screenshot with sections', function () { - return browser - .setupTest('/toolbar.html') - .pause(1000) - .compareScreenshot({ - screenshotName: 'toolbar_section', - selector: '#screenshot-toolbar-sectioned', - checkAccessibility: true - }); - }); -}); diff --git a/src/modules/wait/fixtures/wait.component.visual-fixture.ts b/src/modules/wait/fixtures/wait.component.visual-fixture.ts deleted file mode 100644 index a758ded26..000000000 --- a/src/modules/wait/fixtures/wait.component.visual-fixture.ts +++ /dev/null @@ -1,33 +0,0 @@ -import { Component, NgModule } from '@angular/core'; -import { BrowserModule } from '@angular/platform-browser'; - -import { SkyWaitModule } from '../wait.module'; - -import { Bootstrapper } from '../../../../visual/bootstrapper'; - -@Component({ - selector: 'sky-demo-app', - templateUrl: './wait.component.visual-fixture.html', - styleUrls: ['./wait.component.visual-fixture.scss'] -}) -export class AppComponent { - public isWaiting: boolean; - public isFullPage: boolean; - public isNonBlocking: boolean; -} - -@NgModule({ - imports: [ - BrowserModule, - SkyWaitModule - ], - declarations: [ - AppComponent - ], - bootstrap: [ - AppComponent - ] -}) -class AppModule { } - -Bootstrapper.bootstrapModule(AppModule); diff --git a/src/modules/wait/wait.component.visual-spec.js b/src/modules/wait/wait.component.visual-spec.js deleted file mode 100644 index 4b72c45c2..000000000 --- a/src/modules/wait/wait.component.visual-spec.js +++ /dev/null @@ -1,74 +0,0 @@ -describe('wait component', function () { - 'use strict'; - - it('should display wait on parent', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_component', - selector: '#screenshot-wait', - checkAccessibility: true - }); - }); - - it('should display wait on parent to block absolute item', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_component_absolute', - selector: '#screenshot-wait-absolute', - checkAccessibility: true - }); - }); - - it('should display wait behind parent with modal z-index', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_component_absolute_behind', - selector: '#screenshot-wait-behind', - checkAccessibility: true - }); - }); - - - it('should display nonblocking wait on parent', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-non-blocking') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_component_non_block', - selector: '#screenshot-wait', - checkAccessibility: true - }); - }); - - it('should display wait on full page', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-full-page') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_full_page', - selector: 'body', - checkAccessibility: true - }); - }); - - it('should display non blocking wait on full page', function () { - return browser - .setupTest('/wait.html') - .click('.sky-test-full-page') - .click('.sky-test-non-blocking') - .click('.sky-test-wait') - .compareScreenshot({ - screenshotName: 'wait_full_page_non_block', - selector: 'body', - checkAccessibility: true - }); - }); -}); diff --git a/src/polyfills.ts b/src/polyfills.ts index 8380c3148..85995666e 100644 --- a/src/polyfills.ts +++ b/src/polyfills.ts @@ -17,6 +17,8 @@ import 'ts-helpers'; import 'intl'; import 'intl/locale-data/jsonp/en'; +import 'web-animations-js/web-animations.min'; + // if ('production' === ENV) { // Production // } else { diff --git a/tsconfig.json b/tsconfig.json index 1653ee1b4..729cb0a90 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -17,11 +17,19 @@ "types": [ "jasmine", "node" - ] + ], + "baseUrl": ".", + "paths": { + "@angular/*": ["./node_modules/@angular/*"], + "@blackbaud/skyux/dist/core": ["./src/core.ts"], + "sky-pages-spa/src/*": ["./src/*"], + "sky-pages-internal/*": ["./node_modules/@blackbaud/skyux-builder/*"] + } }, "exclude": [ "node_modules", - "dist" + "dist", + "skyux-spa-visual-tests" ], "compileOnSave": false, "buildOnSave": false, diff --git a/tslint.json b/tslint.json index b40bd3e33..b972c6f5a 100644 --- a/tslint.json +++ b/tslint.json @@ -38,7 +38,6 @@ "curly": true, "forin": true, "label-position": true, - "label-undefined": true, "no-arg": true, "no-bitwise": true, "no-conditional-assignment": true, @@ -52,7 +51,6 @@ ], "no-construct": true, "no-debugger": true, - "no-duplicate-key": true, "no-duplicate-variable": true, "no-empty": false, "no-eval": true, @@ -60,7 +58,6 @@ "no-shadowed-variable": true, "no-string-literal": false, "no-switch-case-fall-through": true, - "no-unreachable": true, "no-unused-expression": true, "no-unused-variable": true, "no-use-before-declare": true, @@ -71,10 +68,6 @@ true, "allow-null-check" ], - "use-strict": [ - true, - "check-module" - ], "eofline": true, "indent": [ @@ -107,7 +100,7 @@ ], "jsdoc-format": true, "no-consecutive-blank-lines": true, - "no-constructor-vars": false, + "no-parameter-properties": false, "one-line": [ true, "check-open-brace", @@ -137,12 +130,8 @@ "check-type" ], - "directive-selector-name": [true, "camelCase"], - "component-selector-name": [true, "kebab-case"], - "directive-selector-type": [true, "attribute"], - "component-selector-type": [true, "element"], - "directive-selector-prefix": [true, "sky"], - "component-selector-prefix": [true, "sky"], + "directive-selector": [true, ["attribute"], "sky", "camelCase"], + "component-selector": [true, ["element"], "sky", "kebab-case"], "use-input-property-decorator": true, "use-output-property-decorator": true, "use-host-property-decorator": true, diff --git a/visual/bootstrapper.ts b/visual/bootstrapper.ts deleted file mode 100644 index e4a067771..000000000 --- a/visual/bootstrapper.ts +++ /dev/null @@ -1,11 +0,0 @@ -import { platformBrowserDynamic } from '@angular/platform-browser-dynamic'; - -const styleLoader = require('../config/utils/sky-style-loader'); - -(window as any).styleLoader = styleLoader; - -export class Bootstrapper { - public static bootstrapModule(moduleType: any) { - platformBrowserDynamic().bootstrapModule(moduleType); - } -} diff --git a/visual/index.ejs b/visual/index.ejs deleted file mode 100644 index ae95fd417..000000000 --- a/visual/index.ejs +++ /dev/null @@ -1,19 +0,0 @@ - - - - Visual Regression - - - -

    Visual Regression

    -
      - <% Object.keys(htmlWebpackPlugin.options.entry).forEach(function (key) { %> -
    • - - <%= key %> - -
    • - <% }) %> -
    - - diff --git a/visual/index.html b/visual/index.html deleted file mode 100644 index 4316429e4..000000000 --- a/visual/index.html +++ /dev/null @@ -1,17 +0,0 @@ - - - - Visual Regression - - - - - - Loading... - - - diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_full.action_button.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_full.action_button.1280px.baseline.png deleted file mode 100644 index 84098fd64..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_full.action_button.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_small_full.action_button_small.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_small_full.action_button_small.480px.baseline.png deleted file mode 100644 index 08d863903..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_action_button_small_full.action_button_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_alert_full.alert.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_alert_full.alert.1280px.baseline.png deleted file mode 100644 index e23ac18b0..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_alert_full.alert.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-image_full.avatar-image.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-image_full.avatar-image.1280px.baseline.png deleted file mode 100644 index 8acca06c5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-image_full.avatar-image.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-initials_full.avatar-initials.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-initials_full.avatar-initials.1280px.baseline.png deleted file mode 100644 index 1963ac6d6..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_avatar-initials_full.avatar-initials.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_hover_full.button_link_hover.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_hover_full.button_link_hover.1280px.baseline.png deleted file mode 100644 index c1ed0b9d6..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_hover_full.button_link_hover.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png deleted file mode 100644 index 31b749989..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-all_full.card-all.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card-all_full.card-all.1280px.baseline.png deleted file mode 100644 index f53e79531..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-all_full.card-all.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noactions_full.card-noactions.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noactions_full.card-noactions.1280px.baseline.png deleted file mode 100644 index cb882368d..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noactions_full.card-noactions.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noheader_full.card-noheader.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noheader_full.card-noheader.1280px.baseline.png deleted file mode 100644 index d33188249..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-noheader_full.card-noheader.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selectable_full.card-selectable.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selectable_full.card-selectable.1280px.baseline.png deleted file mode 100644 index 93372352a..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selectable_full.card-selectable.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selected_full.card-selected.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selected_full.card-selected.1280px.baseline.png deleted file mode 100644 index 93372352a..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card-selected_full.card-selected.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_card_title_overflow_full.card_title_overflow.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_card_title_overflow_full.card_title_overflow.1280px.baseline.png deleted file mode 100644 index 3253bf833..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_card_title_overflow_full.card_title_overflow.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_checkbox_full.checkbox.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_checkbox_full.checkbox.1280px.baseline.png deleted file mode 100644 index 047acb949..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_checkbox_full.checkbox.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_chevron_full.chevron.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_chevron_full.chevron.1280px.baseline.png deleted file mode 100644 index 3e0e9fe29..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_chevron_full.chevron.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png deleted file mode 100644 index 12d1fea97..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_full.datepicker_input.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_full.datepicker_input.1280px.baseline.png deleted file mode 100644 index 59ca896f0..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_full.datepicker_input.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_open_full.datepicker_input_open.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_open_full.datepicker_input_open.1280px.baseline.png deleted file mode 100644 index 4acc64c27..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_input_open_full.datepicker_input_open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png deleted file mode 100644 index d5b77a996..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png deleted file mode 100644 index 78f97a132..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png deleted file mode 100644 index fca0d2c46..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png deleted file mode 100644 index 4958ea6b4..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png deleted file mode 100644 index 47d4f76b1..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png deleted file mode 100644 index 7a7f2cb6c..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png deleted file mode 100644 index 86dcefff9..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png deleted file mode 100644 index 23a2c0eaf..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png deleted file mode 100644 index 3892d0351..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_error-images_full.error-images.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_error-images_full.error-images.1280px.baseline.png deleted file mode 100644 index 8aac132bb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_error-images_full.error-images.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_error-modal-form_full.error-modal-form.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_error-modal-form_full.error-modal-form.1280px.baseline.png deleted file mode 100644 index 15fd553d7..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_error-modal-form_full.error-modal-form.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_file-drop_full.file-drop.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_file-drop_full.file-drop.1280px.baseline.png deleted file mode 100644 index 87803eb4a..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_file-drop_full.file-drop.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_file_drop_nolink_full.file_drop_nolink.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_file_drop_nolink_full.file_drop_nolink.1280px.baseline.png deleted file mode 100644 index 5a80fd4cb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_file_drop_nolink_full.file_drop_nolink.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_active_full.filter_button_active.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_active_full.filter_button_active.1280px.baseline.png deleted file mode 100644 index 399e0edc8..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_active_full.filter_button_active.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_full.filter_button.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_full.filter_button.1280px.baseline.png deleted file mode 100644 index f5f8eeee2..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_button_full.filter_button.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_inline_full.filter_inline.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_inline_full.filter_inline.1280px.baseline.png deleted file mode 100644 index 3af24836d..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_inline_full.filter_inline.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_summary_full.filter_summary.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_summary_full.filter_summary.1280px.baseline.png deleted file mode 100644 index 74ef4662d..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_filter_summary_full.filter_summary.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_full.grid.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_full.grid.1280px.baseline.png deleted file mode 100644 index 330f970bd..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_full.grid.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_asc_full.grid_sort_asc.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_asc_full.grid_sort_asc.1280px.baseline.png deleted file mode 100644 index b1bcf31eb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_asc_full.grid_sort_asc.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_desc_full.grid_sort_desc.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_desc_full.grid_sort_desc.1280px.baseline.png deleted file mode 100644 index 74f6e96c5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_grid_sort_desc_full.grid_sort_desc.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_key-info_full.key-info.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_key-info_full.key-info.1280px.baseline.png deleted file mode 100644 index 753d629cf..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_key-info_full.key-info.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_labels-all_full.labels-all.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_labels-all_full.labels-all.1280px.baseline.png deleted file mode 100644 index 1c6f9f9fd..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_labels-all_full.labels-all.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_secondary_actions_full.list_secondary_actions.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_list_secondary_actions_full.list_secondary_actions.1280px.baseline.png deleted file mode 100644 index 064e79215..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_secondary_actions_full.list_secondary_actions.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_checked_full.list_view_checklist_checked.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_checked_full.list_view_checklist_checked.1280px.baseline.png deleted file mode 100644 index 52961a9a2..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_checked_full.list_view_checklist_checked.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_full.list_view_checklist.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_full.list_view_checklist.1280px.baseline.png deleted file mode 100644 index c59e23c87..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_list_view_checklist_full.list_view_checklist.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_content_only_full.modal_content_only.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_content_only_full.modal_content_only.1280px.baseline.png deleted file mode 100644 index 41a13d14b..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_content_only_full.modal_content_only.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_full.modal.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_full.modal.1280px.baseline.png deleted file mode 100644 index 97ff79f7e..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_full.modal.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_full.modal_large.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_full.modal_large.1280px.baseline.png deleted file mode 100644 index a25850f82..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_full.modal_large.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_mobile_full.modal_large_mobile.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_mobile_full.modal_large_mobile.480px.baseline.png deleted file mode 100644 index 64c11da86..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_mobile_full.modal_large_mobile.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_bounded_full.modal_large_size_bounded.800px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_bounded_full.modal_large_size_bounded.800px.baseline.png deleted file mode 100644 index e694bd199..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_bounded_full.modal_large_size_bounded.800px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_full.modal_large_size.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_full.modal_large_size.1280px.baseline.png deleted file mode 100644 index f7c6a65e3..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_large_size_full.modal_large_size.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_medium_size_full.modal_medium_size.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_medium_size_full.modal_medium_size.1280px.baseline.png deleted file mode 100644 index 41f1b318d..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_medium_size_full.modal_medium_size.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_full.modal_small.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_full.modal_small.480px.baseline.png deleted file mode 100644 index 86835b099..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_full.modal_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_size_full.modal_small_size.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_size_full.modal_small_size.1280px.baseline.png deleted file mode 100644 index 1f3fd47b0..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_modal_small_size_full.modal_small_size.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png deleted file mode 100644 index 43984fa19..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png deleted file mode 100644 index efe71da7a..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png deleted file mode 100644 index e1dced290..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active_full.navbar-item-active.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active_full.navbar-item-active.1280px.baseline.png deleted file mode 100644 index e1dced290..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-active_full.navbar-item-active.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-over_full.navbar-item-over.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-over_full.navbar-item-over.1280px.baseline.png deleted file mode 100644 index c85b835dc..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar-item-over_full.navbar-item-over.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar_full.navbar.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar_full.navbar.1280px.baseline.png deleted file mode 100644 index 9b497db82..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_navbar_full.navbar.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.1280px.baseline.png deleted file mode 100644 index d880d9fdc..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.480px.baseline.png deleted file mode 100644 index 69153ebf9..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_all_full.pagesummary_all.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.1280px.baseline.png deleted file mode 100644 index 139dcc2f6..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.480px.baseline.png deleted file mode 100644 index 0ee26c02f..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_image_title_subtitle_full.pagesummary_image_title_subtitle.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noalert_full.pagesummary_noalert.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noalert_full.pagesummary_noalert.1280px.baseline.png deleted file mode 100644 index d69f91255..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noalert_full.pagesummary_noalert.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nocontent_full.pagesummary_nocontent.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nocontent_full.pagesummary_nocontent.1280px.baseline.png deleted file mode 100644 index 35676f056..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nocontent_full.pagesummary_nocontent.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noimage_full.pagesummary_noimage.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noimage_full.pagesummary_noimage.1280px.baseline.png deleted file mode 100644 index 0388e08f7..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_noimage_full.pagesummary_noimage.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nokeyinfo_full.pagesummary_nokeyinfo.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nokeyinfo_full.pagesummary_nokeyinfo.1280px.baseline.png deleted file mode 100644 index ab8f10a6e..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nokeyinfo_full.pagesummary_nokeyinfo.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nostatus_full.pagesummary_nostatus.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nostatus_full.pagesummary_nostatus.1280px.baseline.png deleted file mode 100644 index b1a827a4e..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nostatus_full.pagesummary_nostatus.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nosubtitle_full.pagesummary_nosubtitle.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nosubtitle_full.pagesummary_nosubtitle.1280px.baseline.png deleted file mode 100644 index 7ed729e12..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_pagesummary_nosubtitle_full.pagesummary_nosubtitle.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_first_full.paging_first.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_first_full.paging_first.1280px.baseline.png deleted file mode 100644 index 5ccec36aa..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_first_full.paging_first.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_middle_full.paging_middle.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_middle_full.paging_middle.1280px.baseline.png deleted file mode 100644 index 24b3478b9..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_paging_middle_full.paging_middle.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_radio_full.radio.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_radio_full.radio.1280px.baseline.png deleted file mode 100644 index 183a3429a..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_radio_full.radio.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-collapsed_full.repeater-collapsed.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-collapsed_full.repeater-collapsed.1280px.baseline.png deleted file mode 100644 index 29020b069..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-collapsed_full.repeater-collapsed.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-multiple_full.repeater-multiple.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-multiple_full.repeater-multiple.1280px.baseline.png deleted file mode 100644 index 49eb2e078..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-multiple_full.repeater-multiple.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-selectable_full.repeater-selectable.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-selectable_full.repeater-selectable.1280px.baseline.png deleted file mode 100644 index 9c805adbb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-selectable_full.repeater-selectable.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-single_full.repeater-single.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-single_full.repeater-single.1280px.baseline.png deleted file mode 100644 index 34cd7727e..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater-single_full.repeater-single.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater_full.repeater.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater_full.repeater.1280px.baseline.png deleted file mode 100644 index 2cc4095e5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_repeater_full.repeater.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_full.search.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_search_full.search.1280px.baseline.png deleted file mode 100644 index a872247a9..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_full.search.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_applied_full.search_small_applied.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_applied_full.search_small_applied.480px.baseline.png deleted file mode 100644 index e462052b8..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_applied_full.search_small_applied.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png deleted file mode 100644 index d9b934c3b..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_full.search_small_dismissable.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_full.search_small_dismissable.480px.baseline.png deleted file mode 100644 index 8aa4ba661..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_dismissable_full.search_small_dismissable.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_full.search_small.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_full.search_small.480px.baseline.png deleted file mode 100644 index 3f96cb4e5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_search_small_full.search_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_full.sort.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_full.sort.1280px.baseline.png deleted file mode 100644 index c3000a2d6..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_full.sort.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_open_full.sort_open.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_open_full.sort_open.1280px.baseline.png deleted file mode 100644 index a5e60469d..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_sort_open_full.sort_open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png deleted file mode 100644 index 459a246a1..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed_full.tabset-collapsed.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed_full.tabset-collapsed.480px.baseline.png deleted file mode 100644 index 3d234d33b..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-collapsed_full.tabset-collapsed.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-wizard_full.tabset-wizard.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-wizard_full.tabset-wizard.1280px.baseline.png deleted file mode 100644 index fdb67c3c5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset-wizard_full.tabset-wizard.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png deleted file mode 100644 index 9bcb53874..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_full.tabset.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_full.tabset.1280px.baseline.png deleted file mode 100644 index eee4a8a65..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tabset_full.tabset.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-modal-expanded_full.text-expand-modal-expanded.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-modal-expanded_full.text-expand-modal-expanded.1280px.baseline.png deleted file mode 100644 index fa769e7ea..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-modal-expanded_full.text-expand-modal-expanded.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-normal-expanded_full.text-expand-normal-expanded.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-normal-expanded_full.text-expand-normal-expanded.1280px.baseline.png deleted file mode 100644 index 59b69fba5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-normal-expanded_full.text-expand-normal-expanded.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-not-expanded_full.text-expand-not-expanded.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-not-expanded_full.text-expand-not-expanded.1280px.baseline.png deleted file mode 100644 index cf14f6fdb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-not-expanded_full.text-expand-not-expanded.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-expanded_full.text-expand-repeater-expanded.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-expanded_full.text-expand-repeater-expanded.1280px.baseline.png deleted file mode 100644 index 10d3b2bab..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-expanded_full.text-expand-repeater-expanded.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-not-expanded_full.text-expand-repeater-not-expanded.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-not-expanded_full.text-expand-repeater-not-expanded.1280px.baseline.png deleted file mode 100644 index 243b3e9f6..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_text-expand-repeater-not-expanded_full.text-expand-repeater-not-expanded.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_full.tile.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_full.tile.1280px.baseline.png deleted file mode 100644 index 8537acf7c..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_full.tile.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_small_full.tile_small.480px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_small_full.tile_small.480px.baseline.png deleted file mode 100644 index 9b7a688f5..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_tile_small_full.tile_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_full.toolbar.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_full.toolbar.1280px.baseline.png deleted file mode 100644 index 53d77e0ff..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_full.toolbar.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_section_full.toolbar_section.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_section_full.toolbar_section.1280px.baseline.png deleted file mode 100644 index 493cde9ea..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_toolbar_section_full.toolbar_section.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_behind_full.wait_component_absolute_behind.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_behind_full.wait_component_absolute_behind.1280px.baseline.png deleted file mode 100644 index a07797f89..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_behind_full.wait_component_absolute_behind.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_full.wait_component_absolute.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_full.wait_component_absolute.1280px.baseline.png deleted file mode 100644 index 63cc744dc..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_absolute_full.wait_component_absolute.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_full.wait_component.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_full.wait_component.1280px.baseline.png deleted file mode 100644 index 41bae78aa..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_full.wait_component.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_non_block_full.wait_component_non_block.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_non_block_full.wait_component_non_block.1280px.baseline.png deleted file mode 100644 index 8f5a60787..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_component_non_block_full.wait_component_non_block.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_full.wait_full_page.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_full.wait_full_page.1280px.baseline.png deleted file mode 100644 index f114fea83..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_full.wait_full_page.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_non_block_full.wait_full_page_non_block.1280px.baseline.png b/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_non_block_full.wait_full_page_non_block.1280px.baseline.png deleted file mode 100644 index cb566f9cb..000000000 Binary files a/webdriver-screenshots/OS X_chrome/OS X_chrome_wait_full_page_non_block_full.wait_full_page_non_block.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_full.action_button.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_full.action_button.1280px.baseline.png deleted file mode 100644 index 3c3a1bfd3..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_full.action_button.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_small_full.action_button_small.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_small_full.action_button_small.480px.baseline.png deleted file mode 100644 index ce41489f9..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_action_button_small_full.action_button_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_alert_full.alert.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_alert_full.alert.1280px.baseline.png deleted file mode 100644 index 69ecc1f3d..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_alert_full.alert.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-image_full.avatar-image.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-image_full.avatar-image.1280px.baseline.png deleted file mode 100644 index 22936b8a3..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-image_full.avatar-image.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-initials_full.avatar-initials.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-initials_full.avatar-initials.1280px.baseline.png deleted file mode 100644 index 0ad60ffc8..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_avatar-initials_full.avatar-initials.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_hover_full.button_link_hover.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_hover_full.button_link_hover.1280px.baseline.png deleted file mode 100644 index 31b3e7da1..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_hover_full.button_link_hover.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png deleted file mode 100644 index 6db81df04..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_button_link_inline_hover_full.button_link_inline_hover.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-all_full.card-all.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_card-all_full.card-all.1280px.baseline.png deleted file mode 100644 index f09f21309..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-all_full.card-all.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noactions_full.card-noactions.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noactions_full.card-noactions.1280px.baseline.png deleted file mode 100644 index 003bab34b..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noactions_full.card-noactions.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noheader_full.card-noheader.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noheader_full.card-noheader.1280px.baseline.png deleted file mode 100644 index 6f0da4890..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-noheader_full.card-noheader.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selectable_full.card-selectable.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selectable_full.card-selectable.1280px.baseline.png deleted file mode 100644 index 1b28e2737..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selectable_full.card-selectable.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selected_full.card-selected.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selected_full.card-selected.1280px.baseline.png deleted file mode 100644 index 1b28e2737..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_card-selected_full.card-selected.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_chevron_full.chevron.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_chevron_full.chevron.1280px.baseline.png deleted file mode 100644 index 31fbbbad1..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_chevron_full.chevron.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png deleted file mode 100644 index 4fb583193..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_daypicker_full.datepicker_daypicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png deleted file mode 100644 index 4f8e6808d..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_monthpicker_full.datepicker_monthpicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png deleted file mode 100644 index 81d0ab86e..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_datepicker_yearpicker_full.datepicker_yearpicker.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png deleted file mode 100644 index cc0bba1dc..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-defaults_full.definition-list-defaults.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png deleted file mode 100644 index 7fe3dcd2a..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_definition-list-overrides_full.definition-list-overrides.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png deleted file mode 100644 index e806b3884..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-closed_full.dropdown-button-closed.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png deleted file mode 100644 index 269167bbf..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-button-open_full.dropdown-button-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png deleted file mode 100644 index 5bd8e42bb..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-closed_full.dropdown-context-menu-closed.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png deleted file mode 100644 index 586c73bc1..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown-context-menu-open_full.dropdown-context-menu-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png deleted file mode 100644 index f7b9b0349..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_dropdown_z_index_full.dropdown_z_index.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_error-images_full.error-images.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_error-images_full.error-images.1280px.baseline.png deleted file mode 100644 index ad93dbbfd..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_error-images_full.error-images.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_labels-all_full.labels-all.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_labels-all_full.labels-all.1280px.baseline.png deleted file mode 100644 index dcd12d885..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_labels-all_full.labels-all.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_content_only_full.modal_content_only.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_content_only_full.modal_content_only.1280px.baseline.png deleted file mode 100644 index a10c8994b..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_content_only_full.modal_content_only.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_full.modal.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_full.modal.1280px.baseline.png deleted file mode 100644 index a817e1a8e..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_full.modal.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_small_full.modal_small.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_small_full.modal_small.480px.baseline.png deleted file mode 100644 index c924dbdb2..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_modal_small_full.modal_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png deleted file mode 100644 index f0b7aebe8..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-item-over_full.navbar-dropdown-item-over.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png deleted file mode 100644 index f9c7c81eb..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-dropdown-open_full.navbar-dropdown-open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png deleted file mode 100644 index 2f9b1bcff..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active-child_full.navbar-item-active-child.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active_full.navbar-item-active.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active_full.navbar-item-active.1280px.baseline.png deleted file mode 100644 index 2f9b1bcff..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-active_full.navbar-item-active.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-over_full.navbar-item-over.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-over_full.navbar-item-over.1280px.baseline.png deleted file mode 100644 index 11749708b..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar-item-over_full.navbar-item-over.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar_full.navbar.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar_full.navbar.1280px.baseline.png deleted file mode 100644 index aa5d00e31..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_navbar_full.navbar.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_radio_full.radio.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_radio_full.radio.1280px.baseline.png deleted file mode 100644 index 598acad6e..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_radio_full.radio.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_applied_full.search_small_applied.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_applied_full.search_small_applied.480px.baseline.png deleted file mode 100644 index 658e0c48a..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_applied_full.search_small_applied.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png deleted file mode 100644 index 3f189d64e..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_dismissable_applied_full.search_small_dismissable_applied.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_full.search_small.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_full.search_small.480px.baseline.png deleted file mode 100644 index 8539bf56d..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_search_small_full.search_small.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_full.sort.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_full.sort.1280px.baseline.png deleted file mode 100644 index fadde0eca..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_full.sort.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_open_full.sort_open.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_open_full.sort_open.1280px.baseline.png deleted file mode 100644 index 48fe686dd..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_sort_open_full.sort_open.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png deleted file mode 100644 index a1ff521d4..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed-dropdown_full.tabset-collapsed-dropdown.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed_full.tabset-collapsed.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed_full.tabset-collapsed.480px.baseline.png deleted file mode 100644 index 11fc34136..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-collapsed_full.tabset-collapsed.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-wizard_full.tabset-wizard.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-wizard_full.tabset-wizard.1280px.baseline.png deleted file mode 100644 index 75c011095..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset-wizard_full.tabset-wizard.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png deleted file mode 100644 index c6ee170ed..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_tabset_collapsed_dropdown_long_full.tabset_collapsed_dropdown_long.480px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_full.toolbar.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_full.toolbar.1280px.baseline.png deleted file mode 100644 index 30a8aec86..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_full.toolbar.1280px.baseline.png and /dev/null differ diff --git a/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_section_full.toolbar_section.1280px.baseline.png b/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_section_full.toolbar_section.1280px.baseline.png deleted file mode 100644 index fe1dadb37..000000000 Binary files a/webdriver-screenshots/OS X_firefox/OS X_firefox_toolbar_section_full.toolbar_section.1280px.baseline.png and /dev/null differ