Moved to https://github.com/elgalu/headless
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//////////////////////////////////////////////// | |
// Protractor Browser Capabilities Extensions // | |
//////////////////////////////////////////////// | |
"use strict"; | |
module.exports = browser.getCapabilities().then(function(s) { | |
var browserName, browserVersion; | |
var shortName, shortVersion; | |
var ie, ff, ch, sa; | |
var platform; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
var maxWaitTimeoutMs = 5000; // 5secs | |
var webdriver = require('selenium-webdriver'); | |
var flow = webdriver.promise.controlFlow(); | |
/** | |
* Custom Jasmine matcher builder that waits for an element to have | |
* or not have an html class. | |
* @param {String} expectation The html class name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- mode: python -*- | |
# | |
# policy for modules to build, options are: | |
# - all: build everything requested | |
# - updated: build only modules that have changed | |
# - updated-deps: build modules that have changed, or their dependencies | |
# have changed. | |
build_policy = 'updated' | |
# moduleset settings: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
////////////////////////// | |
// Some Custom Matchers // | |
////////////////////////// | |
"use strict"; | |
// Usage: | |
// Add `require('./customMatchers.js');` in your onPrepare block or file | |
// Config | |
var specTimeoutMs = 10000; // 10 secs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
browser.getCapabilities().then(function(s) { | |
var browserName, browserVersion; | |
var shortName, shortVersion; | |
var ie, ff, ch, sa; | |
var platform; | |
platform = s.caps_.platform; | |
browserName = s.caps_.browserName; | |
browserVersion = s.caps_.version; | |
shortVersion = browserVersion.split('.')[0]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
unset VNCSERVERARGS | |
VNCSERVERS="" | |
[ -f /etc/headless/vncservers.conf ] && . /etc/headless/vncservers.conf | |
prog=$"VNC server" | |
start() { | |
. /lib/lsb/init-functions | |
REQ_USER=$2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
node node lib/cli.js spec/basicConf.js | |
Using the selenium server at http://satellite.dev:4555/wd/hub | |
[launcher] Running 1 instances of WebDriver....warning: more than one element found for locator by.binding("item.reusedBinding")- you may need to be more specific | |
...............................F................................................F......... | |
Failures: | |
1) protractor library should allow a mix of using protractor and using the driver directly | |
Message: | |
Expected 'http://portege.dev:8000/index.html' to match '#/form'. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @name waitForUrlToChangeTo | |
* @description Wait until the URL changes to match a provided regex | |
* @param {RegExp} urlRegex wait until the URL changes to match this regex | |
* @returns {!webdriver.promise.Promise} Promise | |
*/ | |
function waitForUrlToChangeTo(urlRegex) { | |
var currentUrl; | |
return browser.getCurrentUrl().then(function storeCurrentUrl(url) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Within Mac VM | |
sudo -s | |
# Create user with id 1000 and group with id 1000 | |
dscl . -create /Groups/mygroup | |
dscl . -create /Groups/mygroup name mygroup | |
dscl . -create /Groups/mygroup passwd "clave" | |
dscl . -create /Groups/mygroup gid 1000 | |
dscl . -create /Users/myuser | |
dscl . -create /Users/myuser UserShell /bin/bash | |
dscl . -create /Users/myuser RealName "myuser" |