Skip to content

Instantly share code, notes, and snippets.

Behavior Driven Development

Description of BDD

  • Domain-driven design

Principles of BDD

  • Enough is enough
@webhat
webhat / keeniolab.js
Created June 6, 2013 12:34
Keen.IO Resource Factory with Service Model
'use strict';
angular.module('keeniolab', ['ngResource']).
factory('KeenIO',function ($resource) {
var KeenIO = $resource('https://api.keen.io/3.0/projects/513a76812975164a4a000002/queries/:type',
{
api_key: 'api-key',
event_collection: 'read',
timezone: 7200
}, {
update: { method: 'PUT' }
@webhat
webhat / gist:3772793
Created September 23, 2012 19:44
Add File to Evernote with Tags
on run {input}
tell application "Evernote"
repeat with SelectedFile in input
try
display dialog "Tags for " & SelectedFile default answer ""
set value to text returned of result
set AppleScript's text item delimiters to ","
set the_tags to text items of value
set the_tags to the_tags & {"file", "paper", "book"}