Socket
Socket
Sign inDemoInstall

amaze-tdd

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

amaze-tdd - npm Package Compare versions

Comparing version 0.0.13 to 0.0.14

17

lib/amaze.js

@@ -5,3 +5,3 @@ #!/usr/bin/env node

* Amaze testing suite
* v.0.0.12
* v.0.0.14
*

@@ -23,2 +23,3 @@ * https://npmjs.org/package/amaze-tdd

iedriver = require('../node_modules/iedriver'),
path = require('path'),
glob = require('glob'),

@@ -31,6 +32,7 @@ args = process.argv,

// setup stuff per browser
var driverDir = path.join(__dirname, '../');
if (agent === 'chrome') {
var chrome = require('../node_modules/selenium-webdriver/chrome');
options = new chrome.Options();
options.addExtensions('selenium/crx/5.1.1_0.crx');
options.addExtensions(driverDir + '/selenium/crx/5.1.1_0.crx');
} else if (agent === 'firefox') {

@@ -68,7 +70,8 @@ var firefox = require('../node_modules/selenium-webdriver/firefox');

Agent: agent,
Browser: new webdriver.Builder()
.forBrowser(agent)
// .withCapabilities(webdriver.Capabilities.chrome()) // not sure this is necessary
.setChromeOptions(options)
.build()
Options: options
// Browser: new webdriver.Builder()
// .forBrowser(agent)
// // .withCapabilities(webdriver.Capabilities.chrome()) // not sure this is necessary
// .setChromeOptions(options)
// .build()
};

@@ -75,0 +78,0 @@

{
"name": "amaze-tdd",
"version": "0.0.13",
"version": "0.0.14",
"description": "A package for conducting functional front-end tests.",

@@ -5,0 +5,0 @@ "dependencies": {

@@ -26,2 +26,6 @@ # Amaze test-driven development

Instantiate the browser object:
`var Browser = new Amaze.Webdriver.Builder().forBrowser(Amaze.Agent).setChromeOptions(Amaze.Options).build();`
**Develop mode**

@@ -56,2 +60,6 @@

### 0.0.14
* Making Chrome plugin path work regardless of project
* Moving browser builder to individual tests. This is necessary so the browser can reinstantiate itself between tests.
### 0.0.13

@@ -58,0 +66,0 @@ * Package bin path update

var Amaze = require('../lib/amaze');
var Browser = new Amaze.Webdriver.Builder().forBrowser(Amaze.Agent).setChromeOptions(Amaze.Options).build();

@@ -6,7 +7,7 @@ suite('Visit Google to search', function() {

test('it can navigate to the Google search homepage', function() {
return Amaze.Browser.get('https://www.google.com');
return Browser.get('https://www.google.com');
});
test('it has the correct title', function() {
return Amaze.Browser.getTitle().then(function(title) {
return Browser.getTitle().then(function(title) {
Amaze.Expect(title).to.equal('Google');

@@ -17,3 +18,3 @@ })

test('it can find the search box', function() {
return Amaze.Browser.findElement(Amaze.By.name('q')).then(function(search) {
return Browser.findElement(Amaze.By.name('q')).then(function(search) {
Amaze.Expect(search).to.not.be.null;

@@ -24,7 +25,7 @@ });

test('it can perform a search', function() {
return Amaze.Browser.get('https://www.google.com/?noj=1').then(function() {
return Amaze.Browser.findElement(Amaze.By.name('q')).then(function(search) {
return Browser.get('https://www.google.com/?noj=1').then(function() {
return Browser.findElement(Amaze.By.name('q')).then(function(search) {
return search.sendKeys('Deque accessibility').then(function() {
search.sendKeys(Amaze.Webdriver.Key.ENTER);
return Amaze.Browser.getTitle().then(function(title) {
return Browser.getTitle().then(function(title) {
Amaze.Expect(title).to.equal('Deque accessibility - Google Search');

@@ -38,4 +39,4 @@ });

suiteTeardown(function(done) {
Amaze.Browser.quit().then(done);
Browser.quit().then(done);
});
});
SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc