Skip to content

Instantly share code, notes, and snippets.

View teejayvanslyke's full-sized avatar

Teejay VanSlyke teejayvanslyke

View GitHub Profile
a[href='/random'], a[href='/archive'] {
display: none;
}
.nav ol li {
list-style: none;
}
#upper div {
border-top: none;
describe Sevis::Student do
subject { Sevis::Student.new }
context "when creating" do
context "and its first name is not specified" do
before { Sevis::Student.first_name = nil }
it { should_not be_valid }
specify { subject.errors.size.should_not be_empty }
end
<USAddress>
<Address1>4921 Frost St</Address1>
<Address2>Condo 8a</Address2>
<City>Fairfax</City>
<State>VA</State>
<PostalCode>22031</PostalCode>
<PostalRoutingCode>0000</PostalRoutingCode>
</USAddress>
<ForeignAddress>
<Address1>9334 Katongburg</Address1>
ITU::LegacyCourseManagement::User.create(
:first_name => "Teejay",
:lastname => "Smellsbad",
:usertype => "student",
:email => "teejay.smellsbad@itu.edu",
:student_attributes => {
:firstname => "Teejay",
:lastname => "Smellsbad",
:email => "teejay.smellsbad@itu.edu"
}
require 'csv'
path = 'db/registered_students_fall_2010.csv'
row_index = 0
created_after_9_1 = YAML::load_file('db/created_after_9_1.yml')
p created_after_9_1.size
results = []
[20192, 24060, 20758, 21904, 1548, 24285, 20202, 23260, 2111, 24166, 20344, 21269, 22157, 20887, 23735, 23016, 22138, 22869, 23699, 21398, 22203, 20805, 21338, 22110, 23043, 24115, 23388, 20332, 1624, 1523, 24250, 21325, 20381, 1258, 21115, 20752, 21135, 22373, 2020, 23846, 20867, 21672, 21818, 23675, 1854, 20388, 1556, 853, 23313, 1378, 23495, 20333, 24045, 20711, 20795, 22530, 22109, 20397, 24255, 22815, 21160, 1688, 20015, 2097, 20281, 21027, 23725, 22616, 22407, 23907, 23954, 20580, 1903, 21017, 1714, 22251, 21708, 21710, 22229, 20204, 22282, 1660, 23230, 22429, 22895, 23179, 20343, 23383, 1288, 22494, 1776, 20982, 22186, 23196, 21258, 1622, 21172, 22805, 20476, 24286, 21652, 1470, 22271, 20839, 23860, 21615, 805, 21204, 22148, 21670, 23136, 20207, 20767, 23109, 21254, 20985, 24208, 23653, 20654, 23037, 21622, 22248, 23899, 20541, 22491, 1798, 20843, 1477, 20937, 1584, 21187, 1184, 22310, 22082, 22227, 23969, 23272, 21567, 22412, 22260, 20932, 22255, 1227, 21501, 22931, 24071, 1606, 21089, 23910, 1293, 21
888888b. 888 d8888 888b d888 888
888 "88b 888 d88888 8888b d8888 888
888 .88P 888 d88P888 88888b.d88888 888
8888888K. 888 d88P 888 888Y88888P888 888
888 "Y88b 888 d88P 888 888 Y888P 888 888
888 888 888 d88P 888 888 Y8P 888 Y8P
888 d88P 888 d8888888888 888 " 888 "
8888888P" 88888888 d88P 888 888 888 888
@teejayvanslyke
teejayvanslyke / backbone-jasmine-event-matcher.coffee
Created March 21, 2012 20:26
Jasmine matcher for Backbone.Event expectations
# Usage:
#
# @model.doSomething = ->
# @other_model.trigger('something_done', 'somearg')
#
# expect(=> @model.doSomething()).toTrigger('something_done', on: @other_model, with: [ 'somearg' ])
#
beforeEach ->
$('a[data-mixpanel-tracker]').click ->
setTimeout (=> window.location.href = $(@).attr('href')), 300
tracker = $(@).attr('data-mixpanel-tracker')
properties = JSON.parse($(@).attr('data-mixpanel-properties') || '{}')
mixpanel.track tracker, properties
return false
<html>
<head>
<title>Shuffle</title>
<script>
//BUILD DECK
var suit = ["Hearts", "Spades", "Clubs", "Diamonds"]; // Create the suit array
var face = ["Ace", "1", "2", "3", "4", "5", "6", "7", // Creat face array
"8", "9", "10", "Jack", "Queen", "King"];
//GENERATE RANDOM VALUES FOR 5 DIFFERENT CARDS