Skip to content

Instantly share code, notes, and snippets.

View cobbdb's full-sized avatar

Dan cobbdb

View GitHub Profile
@adjohnston
adjohnston / nav-menu.spec.js
Created July 16, 2015 21:50
WebDriver.IO + Jasmine + PhantomJS Spec Example
describe('adamjohnston.co.uk', function() {
// since I am testing all features found on the same page
// I set url before all the specs.
beforeAll(function (done) {
// elusive browser object, I will find where you're defined!
browser
.url('/') // in the wdio.config.js I have the base url set to my website.
.call(done);
});
@nixjdm
nixjdm / speedtest.sh
Last active July 30, 2023 14:28
This bash script repeatedly tests the page load times of a website and gives some basic stats for the results.
#!/usr/bin/env bash
########################################################################
# Author: Joseph Nix nixjdm@terminallabs.com 6-18-2015
# Copyright (c) 2015 Terminal Labs
# Distributed under the MIT License.
# (See http://opensource.org/licenses/MIT)
#
# This tests the average page load time for a given url. It can be set
# to run any number of tests, and then will average the results.
#
@TakashiSasaki
TakashiSasaki / gist:4282903
Created December 14, 2012 05:32
HTML5 StorageEvent does not fire "storage" event in the window that changes the state of the local storage. This sample shows how to fire self-"storage" event.
<!DOCTYPE html>
<html lang="en" xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<title></title>
</head>
<body>
<script>
"use strict";