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
Feature: Validating user input | |
In order to prevent shipping errors | |
Users input should be validated | |
@javascript | |
Scenario: Client-side form validation | |
Given I am on the form step | |
When I click "Submit" | |
Then I should see validation errors: |
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
/////////////////////// | |
// Image Pre- Loading | |
/////////////////////// | |
// Use a timeout so failing to preload image doesn't stop the page from loading | |
// Can pass 'false' for timeout to never timeout | |
function loadImages (images, callback, timeout) { | |
var img, i, loaded = 0, total = images.length, called = false | |
//console.log('loading images', images.length, images) | |
if (timeout) setTimeout(callCallback, timeout) |
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
class PageObject | |
def click | |
puts 'click' | |
end | |
def submit | |
puts 'submit' | |
end | |
def wait_for_ajax |
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
# Install with: | |
# brew install ffmpeg --HEAD --with-freetype --with--ffplay | |
# http://www.ffmpeg.org/ffmpeg-filters.html#overlay | |
# Make a blank video | |
#ffmpeg -y -filter_complex "color=black:s=960x960:d=6" blank-960x960-6s.mp4 | |
#ffmpeg -y -filter_complex "color=white:s=960x960:d=6" blank-white-960x960-6s.mp4 | |
# | |
# Another way to make backgrounds |
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
ffmpeg -y -re | |
-i /var/www/usp-evaluation/video/v1/deadfall.mp4 | |
-movflags isml+frag_keyframe -f ismv -threads 0 | |
-c:a libfaac -ac 2 -b:a 64k | |
-c:v libx264 -preset fast -profile:v baseline -g 48 -keyint_min 48 -sc_threshold 0 | |
-map 0:v -b:v:0 2877k -s:v:0 1280x720 | |
-map 0:v -b:v:1 1872k -s:v:1 720x404 | |
-map 0:v -b:v:2 1231k -s:v:2 704x396 | |
-map 0:v -b:v:3 830k -s:v:3 640x360 | |
http://localhost/live/live.isml/Streams(video) |
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
var getMapData = function( ) { | |
this.stateOutlines = {}; | |
this.HRROutlines = {}; | |
this.filterableData = {}; | |
this.layersByHRRNUM = {}; | |
var stateJSON = 'assets/js/data/states.json'; | |
var hrrJSON = 'assets/js/data/hospital-referral-regions.json'; |
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
# This file should be at: ~/.ackrc | |
# | |
# ==== | |
# Tipz | |
# ==== | |
# !!! ACK ONLY SEARCHES FILE TYPES IT KNOWS ABOUT !!! | |
# | |
# To search ALL file types, use: | |
# | |
# ack -a pattern |
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
@-webkit-keyframes fade-in { | |
0% { opacity: 0; } | |
100% { opacity: 1; } | |
} | |
@-webkit-keyframes fade-out { | |
0% { opacity: 1; } | |
100% { opacity: 0; } | |
} | |
.animate-fade.ng-hide-add { | |
-webkit-animation: 250ms fade-out; |
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
module.exports = (generate) -> | |
{register, copy, mkdir, set, camelcase} = generate | |
# Register all generators in 1 file | |
# Templates are run through a <%= %> | |
# args are automatically 'set' and available inside templates | |
# extend string prototype w/ handy helpers | |
# need a --dry-run options | |
register(name: "bot", args: "<name>", run: (args) -> | |
mkdir("src/bots/<%= name.camelcase %>") |
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
application.config(($provide) -> | |
# Add timing around $digest() | |
window.digestStats = new DigestStats | |
$provide.decorator("$rootScope", ($delegate) -> | |
$digest = $delegate.$digest.bind($delegate) | |
$delegate.$digest = -> | |
startedAt = performance.now() | |
$digest() | |
digestStats.addDuration(performance.now() - startedAt) |