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_xft yes | |
background yes | |
xftfont verdana:size=8 | |
alignment top_right | |
xftalpha 0.8 | |
own_window yes | |
own_window_type override | |
own_window_transparent yes | |
own_window_hints undecorated,below,sticky,skip_taskbar,skip_pager | |
double_buffer yes |
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
git reflog show | grep '}: commit' | nl | sort -nr | nl | sort -nr | cut --fields=1,3 | sed s/commit://g | sed -e 's/HEAD*@{[0-9]*}://g' |
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
#------------------------------------------------------------------------------------------------------ | |
# Define Caps | |
#------------------------------------------------------------------------------------------------------ | |
profile = Selenium::WebDriver::Firefox::Profile.new | |
profile['general.useragent.override'] = "Mozilla/5.0 (iPhone; U; CPU iPhone OS 3_0 like Mac OS X; en-us) AppleWebKit/528.18 (KHTML, like Gecko) Version/4.0 Mobile/7A341 Safari/528.16" | |
if platform.match(/Firefox/) | |
caps = Selenium::WebDriver::Remote::Capabilities.firefox(:javascript_enabled => true, :firefox_profile=> profile) | |
end |
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
How to Dynamically Add Android Support to Selenium Server at Runtime | |
---------------------------------------------------------------------------------- | |
1) Launch Selenium Server: | |
---------------------------------------------------------------------------------- | |
# In a terminal window, run this command: | |
$ java -jar selenium-server-standalone-2.21.0.jar | |
Apr 25, 2012 3:53:39 PM org.openqa.grid.selenium.GridLauncher main | |
INFO: Launching a standalone server | |
15:53:44.584 INFO - Java: Apple Inc. 20.6-b01-415 |
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/sh | |
# ./bin/behat-ci.sh | |
project_dir=$(dirname $(readlink -f $0))"/.." | |
logs_path=${1:-"./build/logs/behat"} | |
reports_path=${2:-"./build/behat"} | |
cd $project_dir |
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
import time | |
def highlight(element): | |
"""Highlights (blinks) a Selenium Webdriver element""" | |
driver = element._parent | |
def apply_style(s): | |
driver.execute_script("arguments[0].setAttribute('style', arguments[1]);", | |
element, s) | |
original_style = element.get_attribute('style') | |
apply_style("background: yellow; border: 2px solid red;") |
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
<?php | |
use Doctrine\Common\Annotations\AnnotationRegistry; | |
if (!class_exists('Composer\\Autoload\\ClassLoader', false)) { | |
$loader = require __DIR__.'/../vendor/autoload.php'; | |
} else { | |
$loader = new Composer\Autoload\ClassLoader(); | |
$loader->register(); | |
} |
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
grep -ve ^\ *\#'\|'^$ /etc/apache2/apache2.conf |
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
import pytest | |
from selenium.webdriver import Firefox | |
from selenium.webdriver.common.by import By | |
from selenium.webdriver.support.wait import WebDriverWait | |
from selenium.webdriver.support.select import Select | |
from selenium.common.exceptions import UnexpectedTagNameException | |
class ComboBox(object): | |
def __init__(self, webelement): | |
if webelement.tag_name.lower() != "div": |
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
<?php | |
namespace WebDriver; | |
require_once('dashboard.php'); | |
require_once(dirname(__FILE__) . '/../../../PHPWebDriver/WebDriverWait.php'); | |
class SauceLoginPage { | |
private $locators = array( | |
"username" => array("id", 'username'), | |
"password" => array("id", 'password'), |
OlderNewer