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
| describe "given a valiant hero", -> | |
| describe "when she gets crushed by an anvil", -> | |
| it "should play the death music", -> | |
| it "should calculate the final score", -> | |
| it "should update the leader board", -> | |
| it "should play the death animation", -> | |
| describe "when she falls into a pit of spikes", -> | |
| it "should play the death music", -> | |
| it "should calculate the final score", -> |
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
| unbind_all_the_things = (requirejs) -> | |
| defined = requirejs.s.contexts._.defined | |
| requirejs.undef(module) for module in Object.keys(defined) |
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
| define(["game/thing_view"], function(ThingView) { | |
| return function(THREE, bullet) { | |
| var _this = new ThingView(THREE, bullet, "/public/img/tank_bullet.png") | |
| return _this; | |
| } | |
| }); |
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
| draw = function() { | |
| painter.clear(); | |
| things.forEach(function(thing) { | |
| if(thing.active) { | |
| painter.draw(thing); | |
| } | |
| }); | |
| }; |
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
| Dir["lib/*.rb"].each {|f| require File.join(File.dirname(__FILE__), "../", f)} |
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
| describe "tagtastic" do | |
| it "should recurse all the folders lazily" | |
| describe "in preparation mode" do | |
| it "should remove images" | |
| it "should calculate the musicbrainz poid" | |
| it "should store the poid as originalfilename.poid" | |
| it "should look up the musicbrainz data for the poid and store it in originalfilename.json" | |
| it "should log all files with no poid" | |
| end |
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
| describe "a photo" do | |
| it "should have a resource location" | |
| it "should have EXIF data" | |
| it "can include one or more people" | |
| end | |
| describe "a stack" do | |
| it "should have at least one photo" | |
| it "should have at least one bubbled photo" | |
| it "can have zero or more sub stacks" |
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
| def reciprocal integer | |
| 1.0 / integer | |
| end | |
| describe 'reciprocal' do | |
| it 'should return 1 over the integer' do | |
| reciprocal(2).should == 0.5 | |
| end | |
| end |
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
| Feature: Who cares? | |
| Scenario: valid user accounts can log in | |
| When I have a valid user account | |
| Then I can login |
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
| def with object | |
| yield(object) | |
| end | |
| #so I can do this: | |
| with Project.create do |project| | |
| Task.create(:project_id => project.id) | |
| end |