Skip to content

Instantly share code, notes, and snippets.

View devinmancuso's full-sized avatar
🍕
🔥

Devin Mancuso devinmancuso

🍕
🔥
View GitHub Profile
Verifying my Blockstack ID is secured with the address 14jaQq4nVjnNKjtJnFpx4PsqrFg1kUhbqX https://explorer.blockstack.org/address/14jaQq4nVjnNKjtJnFpx4PsqrFg1kUhbqX
@devinmancuso
devinmancuso / ac_injection
Last active November 11, 2015 05:03
Acceptance Criteria Template Injection Bookmarklet
javascript:(function(e,a,g,h,f,c,b,d){
if(!(f=e.jQuery)||g>f.fn.jquery||h(f)){
c=a.createElement("script");
c.type="text/javascript";
c.src="http://ajax.googleapis.com/ajax/libs/jquery/"+g+"/jquery.min.js";
c.onload=c.onreadystatechange=function(){
if(!b&&(!(d=this.readyState)||d=="loaded"||d=="complete")){
h((f=e.jQuery).noConflict(1),b=1);
f(c).remove()}};
@devinmancuso
devinmancuso / minified
Last active August 29, 2015 14:24
Inject browser test status table template into Jira bug ticket description textarea
javascript:(function(e,a,g,h,f,c,b,d){if(!(f=e.jQuery)||g>f.fn.jquery||h(f)){c=a.createElement("script");c.type="text/javascript";c.src="http://ajax.googleapis.com/ajax/libs/jquery/"+g+"/jquery.min.js";c.onload=c.onreadystatechange=function(){if(!b&&(!(d=this.readyState)||d=="loaded"||d=="complete")){h((f=e.jQuery).noConflict(1),b=1);f(c).remove()}};a.documentElement.childNodes[0].appendChild(c)}})(window,document,"1.3.2",function($,L){var caretPos = document.getElementById("description").selectionStart;var textAreaTxt = $("#description").val();var txtToAdd = "\\\\\r\n\\\\\r\n*Testing status*\r\n|| OS X || || || WIN || || || || IPAD || || ANDROID || || || \r\n|| SAFARI || CHROME || FF || IE11 || IE10 || FF || CHROME || SAFARI || CHROME || INTERNET || CHROME || FF ||\r\n| (-) | (-) | (-) | (-) | (-) | (-) | (-) | (-) | (-) | (-) | (-) | (-) |\r\n\\\\\r\n\\\\\r\n";$("#description").val(textAreaTxt.substring(0, caretPos) + txtToAdd + textAreaTxt.substring(caretPos));});
@devinmancuso
devinmancuso / defect_injection
Last active November 7, 2015 01:52
Inject defect reporting template into Jira bug ticket description textarea
javascript:(function(e,a,g,h,f,c,b,d){
if(!(f=e.jQuery)||g>f.fn.jquery||h(f)){
c=a.createElement("script");
c.type="text/javascript";
c.src="http://ajax.googleapis.com/ajax/libs/jquery/"+g+"/jquery.min.js";
c.onload=c.onreadystatechange=function(){
if(!b&&(!(d=this.readyState)||d=="loaded"||d=="complete")){
h((f=e.jQuery).noConflict(1),b=1);
f(c).remove()}};
@devinmancuso
devinmancuso / cleanNBABookmarklet
Last active August 29, 2015 14:23
Remove any spoilers from NBA http://watch.nba.com/nba/ homepage bookmarklet
javascript:(function(e,a,g,h,f,c,b,d){
if(!(f=e.jQuery)||g>f.fn.jquery||h(f)){
c=a.createElement("script");
c.type="text/javascript";
c.src="http://ajax.googleapis.com/ajax/libs/jquery/"+g+"/jquery.min.js";
c.onload=c.onreadystatechange=function(){
if(!b&&(!(d=this.readyState)||d=="loaded"||d=="complete")){
h((f=e.jQuery).noConflict(1),b=1);
f(c).remove()}};
@devinmancuso
devinmancuso / surveymonkeyselenium
Created February 19, 2015 23:54
Selenium Chromedriver to automate Survey Monkey
import time
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from selenium.webdriver.chrome.options import Options
chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument("-incognito")
driver = webdriver.Chrome(executable_path='/Library/Python/2.7/site-packages/selenium/webdriver/chrome/chromedriver', chrome_options=chrome_options)
driver.get('https://www.surveymonkey.com/s/<surveyid>')
time.sleep(2)
nxt_btn = driver.find_element_by_name('NextButton')
@devinmancuso
devinmancuso / driverarraylooper.py
Created December 5, 2014 06:46
Example Python Looping through array of drivers for multiple browser Automated Unit Testing Using Selenium 2 WebDriver
# Import unittest module for creating unit tests
import unittest
# Import time module to implement
import time
# Import the Selenium 2 module (aka "webdriver")
from selenium import webdriver
# For automating data input
@devinmancuso
devinmancuso / PythonAutoTabber.py
Last active August 29, 2015 14:10
Example Python Chrome Keyboard Navigation Automated Unit Testing Using Selenium 2 WebDriver ChromeDriver
# Import unittest module for creating unit tests
import unittest
# Import time module to implement
import time
# Import the Selenium 2 module (aka "webdriver")
from selenium import webdriver
# For automating data input
@devinmancuso
devinmancuso / multibrowsertest.py
Last active August 19, 2021 04:50
Example Python Multiple Browser Automated Unit Testing Using Selenium 2 WebDriver (Chrome and Firefox Separately Defined)
# Import unittest module for creating unit tests
import unittest
# Import time module to implement
import time
# Import the Selenium 2 module (aka "webdriver")
from selenium import webdriver
# For automating data input
@devinmancuso
devinmancuso / Chromium Mobile Device List
Created December 3, 2014 06:01
Mobile Device Emulation List from Chromium
#Pulled from Chromium at: https://code.google.com/p/chromium/codesearch#chromium/src/third_party/WebKit/Source/devtools/front_end/toolbox/OverridesUI.js&q=WebInspector.OverridesUI._phones%20file:OverridesUI.js&sq=package:chromium&type=cs&l=310
#Phones
Define_phones = [
{deviceName: "Apple iPhone 3GS", width: 320, height: 480, deviceScaleFactor: 1, userAgent: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_2_1 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8C148 Safari/6533.18.5", touch: true, mobile: true},
{deviceName: "Apple iPhone 4", width: 320, height: 480, deviceScaleFactor: 2, userAgent: "Mozilla/5.0 (iPhone; U; CPU iPhone OS 4_2_1 like Mac OS X; en-us) AppleWebKit/533.17.9 (KHTML, like Gecko) Version/5.0.2 Mobile/8C148 Safari/6533.18.5", touch: true, mobile: true},
{deviceName: "Apple iPhone 5", width: 320, height: 568, deviceScaleFactor: 2, userAgent: "Mozilla/5.0 (iPhone; CPU iPhone OS 7_0 like Mac OS X; en-us) AppleWebKit/537.51.1 (KHTML, like Gecko) Versi