This file contains hidden or 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
| casper.test.begin 'assertDoesntExist() tests', 1, (test) -> | |
| casper.start().then -> | |
| @setContent '<div class="heaven"></div>' | |
| test.assertDoesntExist '.taxes' | |
| .run -> | |
| test.done() |
This file contains hidden or 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
| BATTLING: Bandit | |
| `'#' | |
| ';::::; | |
| +:::::;:` | |
| ;;::::;::+ | |
| `':::::::;::, | |
| +:::::;:::;+ | |
| '::::::;+;;+++: | |
| #::+, ;;';::::'+##+'## | |
| ;::::#+++''''+#+#'';;;''# |
This file contains hidden or 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
| sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8080 |
This file contains hidden or 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
| /** | |
| * Close an open window. | |
| * <br> | |
| * If you have opened only 1 external window, then when you call this method, the context will switch back to the window you were using before.<br> | |
| * <br> | |
| * If you had more than 2 windows displaying, then you will need to call {@link #switchToWindow(String)} to switch back context. | |
| * @param regex The title of the window to close (regex enabled). You may specify <code>null</code> to close the active window. If you specify <code>null</code> then the context will switch back to the initial window. | |
| * @return | |
| */ | |
| public AutomationTest closeWindow(String regex) { |
This file contains hidden or 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
| $ lsof -n -i4TCP:3000 | grep LISTEN | |
| $ # where 3000 is the port number |
This file contains hidden or 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 | |
| #### | |
| # Author: ddavison | |
| # Description: Download the Mac chromedriver into the current directory | |
| #### | |
| function downloadchrome { | |
| latest=`curl http://chromedriver.storage.googleapis.com/LATEST_RELEASE` | |
| download_location="http://chromedriver.storage.googleapis.com/$latest/chromedriver_mac32.zip" | |
| wget -P /tmp $download_location | |
| unzip /tmp/chromedriver_mac32.zip -d . |
This file contains hidden or 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 | |
| #### | |
| # Author: ddavison | |
| # Description: Download the Linux chromedriver into the current directory | |
| #### | |
| function downloadchrome { | |
| latest=`curl http://chromedriver.storage.googleapis.com/LATEST_RELEASE` | |
| download_location="http://chromedriver.storage.googleapis.com/$latest/chromedriver_linux32.zip" | |
| wget -P /tmp $download_location | |
| unzip /tmp/chromedriver_linux32.zip -d . |
This file contains hidden or 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 | |
| #### | |
| # Author: ddavison | |
| # Description: Download the Linux chromedriver into the current directory | |
| #### | |
| function downloadchrome { | |
| # latest=`curl http://chromedriver.storage.googleapis.com/LATEST_RELEASE` | |
| version="2.9" | |
| download_location="http://chromedriver.storage.googleapis.com/$version/chromedriver_linux32.zip" | |
| rm /tmp/chromedriver_linux32.zip |
This file contains hidden or 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
| function cake-new() { | |
| if [[ $# -lt 1 ]]; then | |
| echo "usage: $0 <app-name>" | |
| else | |
| app_name="$1" | |
| cp -R "/Users/ddavison/workspace/cake-php-base" "/Users/ddavison/workspace/apache/$1" | |
| ln -s /Users/ddavison/workspace/apache/$1/app/Console/cake /Users/ddavison/workspace/apache/$1/cake | |
| chmod -R ugo+rw /Users/ddavison/workspace/apache/$1/app | |
| echo "./cake" >> .gitignore | |
| mv "/Users/ddavison/workspace/apache/$1/app/Config/database.php.default" "/Users/ddavison/workspace/apache/$1/app/Config/database.php" |
This file contains hidden or 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
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "io/ioutil" | |
| "log" | |
| "net/http" | |
| "strconv" | |
| ) |