id
stringlengths
34
124
type
stringclasses
4 values
prompt
stringlengths
0
4.95k
response
stringlengths
21
4.89k
source_lang
stringclasses
3 values
target_lang
stringclasses
2 values
repo
stringclasses
75 values
path
stringlengths
10
88
license
stringclasses
1 value
commit
stringlengths
40
40
stars
int64
431
18.7k
source_url
stringlengths
86
176
line_start
int64
1
214
line_end
int64
3
253
gss/engine:spec/units.coffee:2:raw_corpus
raw_corpus
done() describe 'with non-linear expressions', -> describe 'with unit', -> it 'should be able to compute ratios', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ [">=", ["get", "width"], 50, "weak"], ["<...
CoffeeScript
gss/engine
spec/units.coffee
MIT
daa2a82301cb1696b74d4bda01f1eefdbc0a3151
2,854
https://github.com/gss/engine/blob/daa2a82301cb1696b74d4bda01f1eefdbc0a3151/spec/units.coffee
54
103
gss/engine:spec/units.coffee:2:completion
completion
done() describe 'with non-linear expressions', -> describe 'with unit', -> it 'should be able to compute ratios', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ [">=", ["get", "width"], 50, "weak"], ["<...
done() describe 'with dynamic units', -> describe 'bound to window', -> it 'should be able to compute width', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ ["==", ["get", "a"], 50], [">=", ["get", "wid...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
daa2a82301cb1696b74d4bda01f1eefdbc0a3151
2,854
https://github.com/gss/engine/blob/daa2a82301cb1696b74d4bda01f1eefdbc0a3151/spec/units.coffee
54
103
gss/engine:spec/units.coffee:3:raw_corpus
raw_corpus
remove(engine.id('button1')) engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.data.watchers)).to.eql [] ...
CoffeeScript
gss/engine
spec/units.coffee
MIT
daa2a82301cb1696b74d4bda01f1eefdbc0a3151
2,854
https://github.com/gss/engine/blob/daa2a82301cb1696b74d4bda01f1eefdbc0a3151/spec/units.coffee
104
148
gss/engine:spec/units.coffee:3:completion
completion
remove(engine.id('button1')) engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.data.watchers)).to.eql [] ...
</style> <div id="wrapper" style="font-size: 20px"> <span id="button1"></span> </div> """ engine.then (solution)-> expect(Math.round solution['$button1[width]']).to.eql(Math.round 200) expect(Math.round solution['$button1[height]']).to.eql(Math.round 4...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
daa2a82301cb1696b74d4bda01f1eefdbc0a3151
2,854
https://github.com/gss/engine/blob/daa2a82301cb1696b74d4bda01f1eefdbc0a3151/spec/units.coffee
104
148
gss/engine:spec/units.coffee:3:raw_corpus
raw_corpus
remove(engine.id('button1')) engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql []...
CoffeeScript
gss/engine
spec/units.coffee
MIT
6a63309b1f8130d1e894376c799115b26b037983
2,854
https://github.com/gss/engine/blob/6a63309b1f8130d1e894376c799115b26b037983/spec/units.coffee
104
148
gss/engine:spec/units.coffee:3:completion
completion
remove(engine.id('button1')) engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql []...
</style> <div id="wrapper" style="font-size: 20px"> <span id="button1"></span> </div> """ engine.then (solution)-> expect(Math.round solution['$button1[width]']).to.eql(Math.round 200) expect(Math.round solution['$button1[height]']).to.eql(Math.round 4...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
6a63309b1f8130d1e894376c799115b26b037983
2,854
https://github.com/gss/engine/blob/6a63309b1f8130d1e894376c799115b26b037983/spec/units.coffee
104
148
gss/engine:spec/units.coffee:1:raw_corpus
raw_corpus
remove = (el) -> el?.parentNode?.removeChild(el) describe 'Units', -> engine = container = null beforeEach -> container = document.createElement 'div' $('#fixtures').appendChild container window.$engine = engine = new GSS(container) afterEach -> remove(container) describe 'with conflictin...
CoffeeScript
gss/engine
spec/units.coffee
MIT
10bca5fdbfe6d8db65f0c354bc31b9fd817e263f
2,854
https://github.com/gss/engine/blob/10bca5fdbfe6d8db65f0c354bc31b9fd817e263f/spec/units.coffee
4
53
gss/engine:spec/units.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript remove = (el) -> el?.parentNode?.removeChild(el) describe 'Units', -> engine = container = null beforeEach -> container = document.createElement 'div' $('#fixtures').appendChild container window.$engine = engine = new GSS(container) afterE...
var remove; remove = function(el) { var ref; return el != null ? (ref = el.parentNode) != null ? ref.removeChild(el) : void 0 : void 0; }; describe('Units', function() { var container, engine; engine = container = null; beforeEach(function() { container = document.createElement('div'); $('#fixtures'...
CoffeeScript
JavaScript
gss/engine
spec/units.coffee
MIT
10bca5fdbfe6d8db65f0c354bc31b9fd817e263f
2,854
https://github.com/gss/engine/blob/10bca5fdbfe6d8db65f0c354bc31b9fd817e263f/spec/units.coffee
4
53
gss/engine:spec/units.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var remove; remove = function(el) { var ref; return el != null ? (ref = el.parentNode) != null ? ref.removeChild(el) : void 0 : void 0; }; describe('Units', function() { var container, engine; engine = container = null; beforeEach(function() { conta...
remove = (el) -> el?.parentNode?.removeChild(el) describe 'Units', -> engine = container = null beforeEach -> container = document.createElement 'div' $('#fixtures').appendChild container window.$engine = engine = new GSS(container) afterEach -> remove(container) describe 'with conflictin...
JavaScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
10bca5fdbfe6d8db65f0c354bc31b9fd817e263f
2,854
https://github.com/gss/engine/blob/10bca5fdbfe6d8db65f0c354bc31b9fd817e263f/spec/units.coffee
4
53
gss/engine:spec/units.coffee:1:completion
completion
remove = (el) -> el?.parentNode?.removeChild(el) describe 'Units', -> engine = container = null beforeEach -> container = document.createElement 'div' $('#fixtures').appendChild container window.$engine = engine = new GSS(container) afterEach -> remove(container) describe 'with conflictin...
</style> <button id="button1"></button> """ engine.then (solution)-> expect(solution).to.eql '$button1[width]': 40, '$button1[height]': 120 done() describe 'with unit', -> it 'should resolve constraints separately and ignore conflict', (do...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
10bca5fdbfe6d8db65f0c354bc31b9fd817e263f
2,854
https://github.com/gss/engine/blob/10bca5fdbfe6d8db65f0c354bc31b9fd817e263f/spec/units.coffee
4
53
gss/engine:spec/units.coffee:2:raw_corpus
raw_corpus
done() describe 'with non-linear expressions', -> describe 'with unit', -> it 'should be able to compute ratios', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ [">=", ["get", "width"], 50, "weak"], ["<...
CoffeeScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
54
103
gss/engine:spec/units.coffee:2:completion
completion
done() describe 'with non-linear expressions', -> describe 'with unit', -> it 'should be able to compute ratios', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ [">=", ["get", "width"], 50, "weak"], ["<...
done() describe 'with dynamic units', -> describe 'bound to window', -> it 'should be able to compute width', (done) -> container.innerHTML = """ <style type="text/gss-ast"> ["rule", ["tag", "button"], [ ["==", ["get", "a"], 50], [">=", ["get", "wid...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
54
103
gss/engine:spec/units.coffee:3:raw_corpus
raw_corpus
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.in...
CoffeeScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
104
144
gss/engine:spec/units.coffee:3:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watch...
engine.then(function(solution) { expect(solution['$button1[width]']).to.eql(null); expect(solution['$button1[height]']).to.eql(null); expect(solution['$button1[c]']).to.eql(null); expect(Object.keys(engine.intrinsic.watchers)).to.eql([]); return done(); }); engine.intrinsic.set('::window', 'width', 1000); d...
CoffeeScript
JavaScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
104
144
gss/engine:spec/units.coffee:3:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript engine.then(function(solution) { expect(solution['$button1[width]']).to.eql(null); expect(solution['$button1[height]']).to.eql(null); expect(solution['$button1[c]']).to.eql(null); expect(Object.keys(engine.intrinsic.watchers)).to.eql([]); return done(); }...
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.in...
JavaScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
104
144
gss/engine:spec/units.coffee:3:completion
completion
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.in...
<span id="button1"></span> </div> """ engine.then (solution)-> expect(Math.round solution['$button1[width]']).to.eql(Math.round 200) expect(Math.round solution['$button1[height]']).to.eql(Math.round 40) engine.then (solution) -> expect(Math.round solut...
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
dd16ea9387358f279a6c6c2a602f44874e2d0e6f
2,854
https://github.com/gss/engine/blob/dd16ea9387358f279a6c6c2a602f44874e2d0e6f/spec/units.coffee
104
144
gss/engine:spec/units.coffee:3:raw_corpus
raw_corpus
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.in...
CoffeeScript
gss/engine
spec/units.coffee
MIT
d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0
2,854
https://github.com/gss/engine/blob/d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0/spec/units.coffee
104
112
gss/engine:spec/units.coffee:3:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watch...
engine.then(function(solution) { expect(solution['$button1[width]']).to.eql(null); expect(solution['$button1[height]']).to.eql(null); expect(solution['$button1[c]']).to.eql(null); expect(Object.keys(engine.intrinsic.watchers)).to.eql([]); return done(); }); engine.intrinsic.set('::window', 'width', 1000);
CoffeeScript
JavaScript
gss/engine
spec/units.coffee
MIT
d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0
2,854
https://github.com/gss/engine/blob/d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0/spec/units.coffee
104
112
gss/engine:spec/units.coffee:3:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript engine.then(function(solution) { expect(solution['$button1[width]']).to.eql(null); expect(solution['$button1[height]']).to.eql(null); expect(solution['$button1[c]']).to.eql(null); expect(Object.keys(engine.intrinsic.watchers)).to.eql([]); return done(); }...
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.in...
JavaScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0
2,854
https://github.com/gss/engine/blob/d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0/spec/units.coffee
104
112
gss/engine:spec/units.coffee:3:completion
completion
engine.then (solution)-> expect(solution['$button1[width]']).to.eql null expect(solution['$button1[height]']).to.eql null expect(solution['$button1[c]']).to.eql null
expect(Object.keys(engine.intrinsic.watchers)).to.eql [] done() engine.intrinsic.set('::window', 'width', 1000)
CoffeeScript
CoffeeScript
gss/engine
spec/units.coffee
MIT
d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0
2,854
https://github.com/gss/engine/blob/d3a6c74b85e6d12a9ec02c24fef87d4c22bd9cb0/spec/units.coffee
104
112
twilson63/express-coffee:test/ping_test.coffee:1:raw_corpus
raw_corpus
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"som...
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
baedde8ee076605eeaf56dd50eb72fe6d5621f8e
622
https://github.com/twilson63/express-coffee/blob/baedde8ee076605eeaf56dd50eb72fe6d5621f8e/test/ping_test.coffee
1
27
twilson63/express-coffee:test/ping_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done...
var app, request; request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "hello": ["world"] }, done); }); return it("should respond with sent data", fun...
CoffeeScript
JavaScript
twilson63/express-coffee
test/ping_test.coffee
MIT
baedde8ee076605eeaf56dd50eb72fe6d5621f8e
622
https://github.com/twilson63/express-coffee/blob/baedde8ee076605eeaf56dd50eb72fe6d5621f8e/test/ping_test.coffee
1
27
twilson63/express-coffee:test/ping_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var app, request; request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "hello": ["world"] }, done);...
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"som...
JavaScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
baedde8ee076605eeaf56dd50eb72fe6d5621f8e
622
https://github.com/twilson63/express-coffee/blob/baedde8ee076605eeaf56dd50eb72fe6d5621f8e/test/ping_test.coffee
1
27
twilson63/express-coffee:test/ping_test.coffee:1:completion
completion
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"som...
id = "4" request(app) .post("/ping/pong/#{id}?q=something") .send(pongData) .expect(200, (err, res) -> res.body.should.have.property "pongQuery" res.body.should.have.property "pongBody" res.body.should.have.property "id" res.body.pongQuery.should.eql query r...
CoffeeScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
baedde8ee076605eeaf56dd50eb72fe6d5621f8e
622
https://github.com/twilson63/express-coffee/blob/baedde8ee076605eeaf56dd50eb72fe6d5621f8e/test/ping_test.coffee
1
27
twilson63/express-coffee:test/ping_test.coffee:1:raw_corpus
raw_corpus
puts = require 'puts' request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data...
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
3da2827dff738c8e9b45eb8c1491a97096209eba
622
https://github.com/twilson63/express-coffee/blob/3da2827dff738c8e9b45eb8c1491a97096209eba/test/ping_test.coffee
1
32
twilson63/express-coffee:test/ping_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript puts = require 'puts' request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respon...
var app, puts, request; puts = require('puts'); request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "hello": ["world"] }, done); }); return it("shou...
CoffeeScript
JavaScript
twilson63/express-coffee
test/ping_test.coffee
MIT
3da2827dff738c8e9b45eb8c1491a97096209eba
622
https://github.com/twilson63/express-coffee/blob/3da2827dff738c8e9b45eb8c1491a97096209eba/test/ping_test.coffee
1
32
twilson63/express-coffee:test/ping_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var app, puts, request; puts = require('puts'); request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "...
puts = require 'puts' request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data...
JavaScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
3da2827dff738c8e9b45eb8c1491a97096209eba
622
https://github.com/twilson63/express-coffee/blob/3da2827dff738c8e9b45eb8c1491a97096209eba/test/ping_test.coffee
1
32
twilson63/express-coffee:test/ping_test.coffee:1:completion
completion
puts = require 'puts' request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data...
id = "4" request(app) .post("/ping/pong/#{id}?q=something") .send(pongData) .expect(200, (err, res) -> puts {"hello":["some"]} res.body.should.have.property "pongQuery" res.body.should.have.property "pongBody" res.body.should.have.property "id" res.body.pon...
CoffeeScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
3da2827dff738c8e9b45eb8c1491a97096209eba
622
https://github.com/twilson63/express-coffee/blob/3da2827dff738c8e9b45eb8c1491a97096209eba/test/ping_test.coffee
1
32
twilson63/express-coffee:test/ping_test.coffee:1:raw_corpus
raw_corpus
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"somet...
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
169922f2a13b8a475acd641c921e2b2f85285f0a
622
https://github.com/twilson63/express-coffee/blob/169922f2a13b8a475acd641c921e2b2f85285f0a/test/ping_test.coffee
1
26
twilson63/express-coffee:test/ping_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) ...
var app, request; request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "hello": ["world"] }, done); }); return it("should respond with sent data", fun...
CoffeeScript
JavaScript
twilson63/express-coffee
test/ping_test.coffee
MIT
169922f2a13b8a475acd641c921e2b2f85285f0a
622
https://github.com/twilson63/express-coffee/blob/169922f2a13b8a475acd641c921e2b2f85285f0a/test/ping_test.coffee
1
26
twilson63/express-coffee:test/ping_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var app, request; request = require('supertest'); app = require(process.cwd() + '/.app'); describe('Ping Pong', function() { it("should say hello world", function(done) { return request(app).get("/ping").expect(200, { "hello": ["world"] }, done);...
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"somet...
JavaScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
169922f2a13b8a475acd641c921e2b2f85285f0a
622
https://github.com/twilson63/express-coffee/blob/169922f2a13b8a475acd641c921e2b2f85285f0a/test/ping_test.coffee
1
26
twilson63/express-coffee:test/ping_test.coffee:1:completion
completion
request = require 'supertest' app = require process.cwd() + '/.app' describe 'Ping Pong', -> it "should say hello world", (done) -> request(app) .get("/ping") .expect(200, {"hello":["world"]}, done) it "should respond with sent data", (done) -> pongData = {"pong":"data"} query = {"q":"somet...
.post("/ping/pong/#{id}?q=something") .send(pongData) .expect(200, (err, res) -> # puts res res.body.should.have.property "pongQuery" res.body.should.have.property "pongBody" res.body.should.have.property "id" res.body.pongQuery.should.eql query res.body.pongB...
CoffeeScript
CoffeeScript
twilson63/express-coffee
test/ping_test.coffee
MIT
169922f2a13b8a475acd641c921e2b2f85285f0a
622
https://github.com/twilson63/express-coffee/blob/169922f2a13b8a475acd641c921e2b2f85285f0a/test/ping_test.coffee
1
26
twilson63/express-coffee:lib/coffee/lib/coffee-script/src/cake.coffee:1:raw_corpus
raw_corpus
# `cake` is a simplified version of [Make](http://www.gnu.org/software/make/) # ([Rake](http://rake.rubyforge.org/), [Jake](http://github.com/280north/jake)) # for CoffeeScript. You define tasks with names and descriptions in a Cakefile, # and can call them from the command line, or invoke them from other tasks. # # Ru...
CoffeeScript
twilson63/express-coffee
lib/coffee/lib/coffee-script/src/cake.coffee
MIT
971837f7d7a5e96cf5a5fdb52e52748060ed2c68
622
https://github.com/twilson63/express-coffee/blob/971837f7d7a5e96cf5a5fdb52e52748060ed2c68/lib/coffee/lib/coffee-script/src/cake.coffee
1
50
twilson63/express-coffee:lib/coffee/lib/coffee-script/src/cake.coffee:1:completion
completion
# `cake` is a simplified version of [Make](http://www.gnu.org/software/make/) # ([Rake](http://rake.rubyforge.org/), [Jake](http://github.com/280north/jake)) # for CoffeeScript. You define tasks with names and descriptions in a Cakefile, # and can call them from the command line, or invoke them from other tasks. # # Ru...
# and the function to run as the action itself. task: (name, description, action) -> [action, description]: [description, action] unless action tasks[name]: {name: name, description: description, action: action} # Define an option that the Cakefile accepts. The parsed options hash, # containing all of th...
CoffeeScript
CoffeeScript
twilson63/express-coffee
lib/coffee/lib/coffee-script/src/cake.coffee
MIT
971837f7d7a5e96cf5a5fdb52e52748060ed2c68
622
https://github.com/twilson63/express-coffee/blob/971837f7d7a5e96cf5a5fdb52e52748060ed2c68/lib/coffee/lib/coffee-script/src/cake.coffee
1
50
twilson63/express-coffee:lib/coffee/lib/coffee-script/src/cake.coffee:2:raw_corpus
raw_corpus
CoffeeScript.run fs.readFileSync('Cakefile').toString(), {source: 'Cakefile'} oparse: new optparse.OptionParser switches return print_tasks() unless args.length options: oparse.parse(args) invoke arg for arg in options.arguments # Display the list of Cake tasks in a format similar to `rake -T` print_ta...
CoffeeScript
twilson63/express-coffee
lib/coffee/lib/coffee-script/src/cake.coffee
MIT
971837f7d7a5e96cf5a5fdb52e52748060ed2c68
622
https://github.com/twilson63/express-coffee/blob/971837f7d7a5e96cf5a5fdb52e52748060ed2c68/lib/coffee/lib/coffee-script/src/cake.coffee
51
70
twilson63/express-coffee:lib/coffee/lib/coffee-script/src/cake.coffee:2:completion
completion
CoffeeScript.run fs.readFileSync('Cakefile').toString(), {source: 'Cakefile'} oparse: new optparse.OptionParser switches return print_tasks() unless args.length options: oparse.parse(args) invoke arg for arg in options.arguments # Display the list of Cake tasks in a format similar to `rake -T` print_ta...
spaces: 20 - name.length spaces: if spaces > 0 then (' ' for i in [0..spaces]).join('') else '' desc: if task.description then "# $task.description" else '' puts "cake $name$spaces $desc" puts oparse.help() if switches.length # Print an error and exit when attempting to all an undefined task. no_such_t...
CoffeeScript
CoffeeScript
twilson63/express-coffee
lib/coffee/lib/coffee-script/src/cake.coffee
MIT
971837f7d7a5e96cf5a5fdb52e52748060ed2c68
622
https://github.com/twilson63/express-coffee/blob/971837f7d7a5e96cf5a5fdb52e52748060ed2c68/lib/coffee/lib/coffee-script/src/cake.coffee
51
70
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:raw_corpus
raw_corpus
suite 'attribute() Guards:', -> test 'Throw if null attribute (att)', -> err( () -> xml('test4', { headless: true }).ele('node').att(null, '') Error "Missing attribute name. parent: <node>" )
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1
926
https://github.com/oozcitak/xmlbuilder-js/blob/ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1/test/guards/attributes.coffee
1
7
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript suite 'attribute() Guards:', -> test 'Throw if null attribute (att)', -> err( () -> xml('test4', { headless: true }).ele('node').att(null, '') Error "Missing attribute name. parent: <node>" ) ```
suite('attribute() Guards:', function() { return test('Throw if null attribute (att)', function() { return err(function() { return xml('test4', { headless: true }).ele('node').att(null, ''); }, Error, "Missing attribute name. parent: <node>"); }); });
CoffeeScript
JavaScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1
926
https://github.com/oozcitak/xmlbuilder-js/blob/ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1/test/guards/attributes.coffee
1
7
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript suite('attribute() Guards:', function() { return test('Throw if null attribute (att)', function() { return err(function() { return xml('test4', { headless: true }).ele('node').att(null, ''); }, Error, "Missing attribute name. parent: <...
suite 'attribute() Guards:', -> test 'Throw if null attribute (att)', -> err( () -> xml('test4', { headless: true }).ele('node').att(null, '') Error "Missing attribute name. parent: <node>" )
JavaScript
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1
926
https://github.com/oozcitak/xmlbuilder-js/blob/ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1/test/guards/attributes.coffee
1
7
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:completion
completion
suite 'attribute() Guards:', -> test 'Throw if null attribute (att)', -> err(
() -> xml('test4', { headless: true }).ele('node').att(null, '') Error "Missing attribute name. parent: <node>" )
CoffeeScript
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1
926
https://github.com/oozcitak/xmlbuilder-js/blob/ce625aeb9f52d1f75d5d94260794d3b5fd74a8b1/test/guards/attributes.coffee
1
7
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:raw_corpus
raw_corpus
suite 'attribute() Guards:', -> test 'Throw if null attribute (ele)', -> err( () -> xml('test4', { headless: true }).ele('node', 'element', {"first": null, "second":"2"}) Error "Missing attribute value. attribute: {first}, parent: <node>" ) test 'Throw if null attribute (att)', -> err...
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
f066a3151d269e738ea37d87e5bf2470ef948b24
926
https://github.com/oozcitak/xmlbuilder-js/blob/f066a3151d269e738ea37d87e5bf2470ef948b24/test/guards/attributes.coffee
1
35
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript suite 'attribute() Guards:', -> test 'Throw if null attribute (ele)', -> err( () -> xml('test4', { headless: true }).ele('node', 'element', {"first": null, "second":"2"}) Error "Missing attribute value. attribute: {first}, parent: <node>" ...
suite('attribute() Guards:', function() { test('Throw if null attribute (ele)', function() { return err(function() { return xml('test4', { headless: true }).ele('node', 'element', { "first": null, "second": "2" }); }, Error, "Missing attribute value. attribute: {first...
CoffeeScript
JavaScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
f066a3151d269e738ea37d87e5bf2470ef948b24
926
https://github.com/oozcitak/xmlbuilder-js/blob/f066a3151d269e738ea37d87e5bf2470ef948b24/test/guards/attributes.coffee
1
35
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript suite('attribute() Guards:', function() { test('Throw if null attribute (ele)', function() { return err(function() { return xml('test4', { headless: true }).ele('node', 'element', { "first": null, "second": "2" }); ...
suite 'attribute() Guards:', -> test 'Throw if null attribute (ele)', -> err( () -> xml('test4', { headless: true }).ele('node', 'element', {"first": null, "second":"2"}) Error "Missing attribute value. attribute: {first}, parent: <node>" ) test 'Throw if null attribute (att)', -> err...
JavaScript
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
f066a3151d269e738ea37d87e5bf2470ef948b24
926
https://github.com/oozcitak/xmlbuilder-js/blob/f066a3151d269e738ea37d87e5bf2470ef948b24/test/guards/attributes.coffee
1
35
oozcitak/xmlbuilder-js:test/guards/attributes.coffee:1:completion
completion
suite 'attribute() Guards:', -> test 'Throw if null attribute (ele)', -> err( () -> xml('test4', { headless: true }).ele('node', 'element', {"first": null, "second":"2"}) Error "Missing attribute value. attribute: {first}, parent: <node>" ) test 'Throw if null attribute (att)', -> err...
() -> xml('test4', { headless: true }).ele('node').att(null, "first") Error "Missing attribute name. parent: <node>" ) test 'Throw if null attribute value (att)', -> err( () -> xml('test4', { headless: true }).ele('node').att("first", null) Error "Missing attribute value. attrib...
CoffeeScript
CoffeeScript
oozcitak/xmlbuilder-js
test/guards/attributes.coffee
MIT
f066a3151d269e738ea37d87e5bf2470ef948b24
926
https://github.com/oozcitak/xmlbuilder-js/blob/f066a3151d269e738ea37d87e5bf2470ef948b24/test/guards/attributes.coffee
1
35
meltingice/psd.js:lib/psd/image_formats/layer_rle.coffee:1:raw_corpus
raw_corpus
module.exports = parseByteCounts: -> @file.readShort() for i in [0...@height()] parseChannelData: -> @lineIndex = 0 @decodeRLEChannel()
CoffeeScript
meltingice/psd.js
lib/psd/image_formats/layer_rle.coffee
MIT
7e8392d20fd5d66ad70ddda7309661b9a0ca67c8
2,846
https://github.com/meltingice/psd.js/blob/7e8392d20fd5d66ad70ddda7309661b9a0ca67c8/lib/psd/image_formats/layer_rle.coffee
1
7
meltingice/psd.js:lib/psd/image_formats/layer_rle.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = parseByteCounts: -> @file.readShort() for i in [0...@height()] parseChannelData: -> @lineIndex = 0 @decodeRLEChannel() ```
module.exports = { parseByteCounts: function() { var i, j, ref, results; results = []; for (i = j = 0, ref = this.height(); (0 <= ref ? j < ref : j > ref); i = 0 <= ref ? ++j : --j) { results.push(this.file.readShort()); } return results; }, parseChannelData: function() { this.lineIn...
CoffeeScript
JavaScript
meltingice/psd.js
lib/psd/image_formats/layer_rle.coffee
MIT
7e8392d20fd5d66ad70ddda7309661b9a0ca67c8
2,846
https://github.com/meltingice/psd.js/blob/7e8392d20fd5d66ad70ddda7309661b9a0ca67c8/lib/psd/image_formats/layer_rle.coffee
1
7
meltingice/psd.js:lib/psd/image_formats/layer_rle.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = { parseByteCounts: function() { var i, j, ref, results; results = []; for (i = j = 0, ref = this.height(); (0 <= ref ? j < ref : j > ref); i = 0 <= ref ? ++j : --j) { results.push(this.file.readShort()); } return results...
module.exports = parseByteCounts: -> @file.readShort() for i in [0...@height()] parseChannelData: -> @lineIndex = 0 @decodeRLEChannel()
JavaScript
CoffeeScript
meltingice/psd.js
lib/psd/image_formats/layer_rle.coffee
MIT
7e8392d20fd5d66ad70ddda7309661b9a0ca67c8
2,846
https://github.com/meltingice/psd.js/blob/7e8392d20fd5d66ad70ddda7309661b9a0ca67c8/lib/psd/image_formats/layer_rle.coffee
1
7
meltingice/psd.js:lib/psd/image_formats/layer_rle.coffee:1:completion
completion
module.exports = parseByteCounts: -> @file.readShort() for i in [0...@height()]
parseChannelData: -> @lineIndex = 0 @decodeRLEChannel()
CoffeeScript
CoffeeScript
meltingice/psd.js
lib/psd/image_formats/layer_rle.coffee
MIT
7e8392d20fd5d66ad70ddda7309661b9a0ca67c8
2,846
https://github.com/meltingice/psd.js/blob/7e8392d20fd5d66ad70ddda7309661b9a0ca67c8/lib/psd/image_formats/layer_rle.coffee
1
7
linemanjs/lineman:config/plugins/less.coffee:1:raw_corpus
raw_corpus
module.exports = (lineman) -> config: less: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
933adfea4b35d36c79ddfacdfc6c2b5330dd6e81
1,168
https://github.com/linemanjs/lineman/blob/933adfea4b35d36c79ddfacdfc6c2b5330dd6e81/config/plugins/less.coffee
1
9
linemanjs/lineman:config/plugins/less.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = (lineman) -> config: less: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= file...
module.exports = function(lineman) { return { config: { less: { options: { paths: ["app/css", "vendor/css"] }, compile: { files: { "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>", "<%= files.less.generatedApp %>": "<%= files...
CoffeeScript
JavaScript
linemanjs/lineman
config/plugins/less.coffee
MIT
933adfea4b35d36c79ddfacdfc6c2b5330dd6e81
1,168
https://github.com/linemanjs/lineman/blob/933adfea4b35d36c79ddfacdfc6c2b5330dd6e81/config/plugins/less.coffee
1
9
linemanjs/lineman:config/plugins/less.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = function(lineman) { return { config: { less: { options: { paths: ["app/css", "vendor/css"] }, compile: { files: { "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>", ...
module.exports = (lineman) -> config: less: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
JavaScript
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
933adfea4b35d36c79ddfacdfc6c2b5330dd6e81
1,168
https://github.com/linemanjs/lineman/blob/933adfea4b35d36c79ddfacdfc6c2b5330dd6e81/config/plugins/less.coffee
1
9
linemanjs/lineman:config/plugins/less.coffee:1:completion
completion
module.exports = (lineman) -> config: less: options:
paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
CoffeeScript
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
933adfea4b35d36c79ddfacdfc6c2b5330dd6e81
1,168
https://github.com/linemanjs/lineman/blob/933adfea4b35d36c79ddfacdfc6c2b5330dd6e81/config/plugins/less.coffee
1
9
linemanjs/lineman:config/plugins/less.coffee:1:raw_corpus
raw_corpus
module.exports = (lineman) -> config: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
94365fc4e4b804de8672585c254895fbd9cb514e
1,168
https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/less.coffee
1
8
linemanjs/lineman:config/plugins/less.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = (lineman) -> config: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>" ```
module.exports = function(lineman) { return { config: { options: { paths: ["app/css", "vendor/css"] }, compile: { files: { "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>", "<%= files.less.generatedApp %>": "<%= files.less.app %>" } ...
CoffeeScript
JavaScript
linemanjs/lineman
config/plugins/less.coffee
MIT
94365fc4e4b804de8672585c254895fbd9cb514e
1,168
https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/less.coffee
1
8
linemanjs/lineman:config/plugins/less.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = function(lineman) { return { config: { options: { paths: ["app/css", "vendor/css"] }, compile: { files: { "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>", "<%= files.less.g...
module.exports = (lineman) -> config: options: paths: ["app/css", "vendor/css"] compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
JavaScript
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
94365fc4e4b804de8672585c254895fbd9cb514e
1,168
https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/less.coffee
1
8
linemanjs/lineman:config/plugins/less.coffee:1:completion
completion
module.exports = (lineman) -> config: options: paths: ["app/css", "vendor/css"]
compile: files: "<%= files.less.generatedVendor %>": "<%= files.less.vendor %>" "<%= files.less.generatedApp %>": "<%= files.less.app %>"
CoffeeScript
CoffeeScript
linemanjs/lineman
config/plugins/less.coffee
MIT
94365fc4e4b804de8672585c254895fbd9cb514e
1,168
https://github.com/linemanjs/lineman/blob/94365fc4e4b804de8672585c254895fbd9cb514e/config/plugins/less.coffee
1
8
linemanjs/lineman:lib/hooks.coffee:1:raw_corpus
raw_corpus
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> hook = "hooks.#{address}" if handler = readsConfiguration.read(hook) try handler(address, args...) catch e console.warn """ ...
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
61d681532d9621e578d319c279006bbb728ece4b
1,168
https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/lib/hooks.coffee
1
23
linemanjs/lineman:lib/hooks.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> hook = "hooks.#{address}" if handler = readsConfiguration.read(hook) try handler(address, ...
var ReadsConfiguration, readsConfiguration; ReadsConfiguration = require('./reads-configuration'); readsConfiguration = new ReadsConfiguration(); module.exports = { trigger: function(address, ...args) { var e, handler, hook; hook = `hooks.${address}`; if (handler = readsConfiguration.read(hook)) { ...
CoffeeScript
JavaScript
linemanjs/lineman
lib/hooks.coffee
MIT
61d681532d9621e578d319c279006bbb728ece4b
1,168
https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/lib/hooks.coffee
1
23
linemanjs/lineman:lib/hooks.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var ReadsConfiguration, readsConfiguration; ReadsConfiguration = require('./reads-configuration'); readsConfiguration = new ReadsConfiguration(); module.exports = { trigger: function(address, ...args) { var e, handler, hook; hook = `hooks.${address}`; ...
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> hook = "hooks.#{address}" if handler = readsConfiguration.read(hook) try handler(address, args...) catch e console.warn """ ...
JavaScript
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
61d681532d9621e578d319c279006bbb728ece4b
1,168
https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/lib/hooks.coffee
1
23
linemanjs/lineman:lib/hooks.coffee:1:completion
completion
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> hook = "hooks.#{address}" if handler = readsConfiguration.read(hook) try handler(address, args...) catch e console.warn """
Encountered an exception while invoking hook '#{hook}': Error: #{e.message} Hook source: #{handler.toString()} """ throw e
CoffeeScript
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
61d681532d9621e578d319c279006bbb728ece4b
1,168
https://github.com/linemanjs/lineman/blob/61d681532d9621e578d319c279006bbb728ece4b/lib/hooks.coffee
1
23
linemanjs/lineman:lib/hooks.coffee:1:raw_corpus
raw_corpus
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> if handler = readsConfiguration.read("hooks.#{address}") handler(address, args...)
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
2cf8a8fa540d676691bf7ac80c643622afc426f7
1,168
https://github.com/linemanjs/lineman/blob/2cf8a8fa540d676691bf7ac80c643622afc426f7/lib/hooks.coffee
1
7
linemanjs/lineman:lib/hooks.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> if handler = readsConfiguration.read("hooks.#{address}") handler(address, args...) ```
var ReadsConfiguration, readsConfiguration; ReadsConfiguration = require('./reads-configuration'); readsConfiguration = new ReadsConfiguration(); module.exports = { trigger: function(address, ...args) { var handler; if (handler = readsConfiguration.read(`hooks.${address}`)) { return handler(address, ...
CoffeeScript
JavaScript
linemanjs/lineman
lib/hooks.coffee
MIT
2cf8a8fa540d676691bf7ac80c643622afc426f7
1,168
https://github.com/linemanjs/lineman/blob/2cf8a8fa540d676691bf7ac80c643622afc426f7/lib/hooks.coffee
1
7
linemanjs/lineman:lib/hooks.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var ReadsConfiguration, readsConfiguration; ReadsConfiguration = require('./reads-configuration'); readsConfiguration = new ReadsConfiguration(); module.exports = { trigger: function(address, ...args) { var handler; if (handler = readsConfiguration.rea...
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration() module.exports = trigger: (address, args...) -> if handler = readsConfiguration.read("hooks.#{address}") handler(address, args...)
JavaScript
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
2cf8a8fa540d676691bf7ac80c643622afc426f7
1,168
https://github.com/linemanjs/lineman/blob/2cf8a8fa540d676691bf7ac80c643622afc426f7/lib/hooks.coffee
1
7
linemanjs/lineman:lib/hooks.coffee:1:completion
completion
ReadsConfiguration = require('./reads-configuration') readsConfiguration = new ReadsConfiguration()
module.exports = trigger: (address, args...) -> if handler = readsConfiguration.read("hooks.#{address}") handler(address, args...)
CoffeeScript
CoffeeScript
linemanjs/lineman
lib/hooks.coffee
MIT
2cf8a8fa540d676691bf7ac80c643622afc426f7
1,168
https://github.com/linemanjs/lineman/blob/2cf8a8fa540d676691bf7ac80c643622afc426f7/lib/hooks.coffee
1
7
jianliaoim/talk-os:talk-web/test/spec/util/pinyin.spec.coffee:1:raw_corpus
raw_corpus
Immutable = require 'immutable' describe 'util: search', -> beforeEach -> @pinyin = require 'util/pinyin' describe 'function: make', -> it 'should make pinyin', -> expect(@pinyin.make('测试')).toEqualImmutable Immutable.fromJS { pinyin: 'ceshi' pinyins: ['ceshi'] py: 'cs' ...
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/util/pinyin.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/util/pinyin.spec.coffee
1
43
jianliaoim/talk-os:talk-web/test/spec/util/pinyin.spec.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript Immutable = require 'immutable' describe 'util: search', -> beforeEach -> @pinyin = require 'util/pinyin' describe 'function: make', -> it 'should make pinyin', -> expect(@pinyin.make('测试')).toEqualImmutable Immutable.fromJS { pinyin:...
var Immutable; Immutable = require('immutable'); describe('util: search', function() { beforeEach(function() { return this.pinyin = require('util/pinyin'); }); return describe('function: make', function() { it('should make pinyin', function() { return expect(this.pinyin.make('测试')).toEqualImmutabl...
CoffeeScript
JavaScript
jianliaoim/talk-os
talk-web/test/spec/util/pinyin.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/util/pinyin.spec.coffee
1
43
jianliaoim/talk-os:talk-web/test/spec/util/pinyin.spec.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var Immutable; Immutable = require('immutable'); describe('util: search', function() { beforeEach(function() { return this.pinyin = require('util/pinyin'); }); return describe('function: make', function() { it('should make pinyin', function() { ...
Immutable = require 'immutable' describe 'util: search', -> beforeEach -> @pinyin = require 'util/pinyin' describe 'function: make', -> it 'should make pinyin', -> expect(@pinyin.make('测试')).toEqualImmutable Immutable.fromJS { pinyin: 'ceshi' pinyins: ['ceshi'] py: 'cs' ...
JavaScript
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/util/pinyin.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/util/pinyin.spec.coffee
1
43
jianliaoim/talk-os:talk-web/test/spec/util/pinyin.spec.coffee:1:completion
completion
Immutable = require 'immutable' describe 'util: search', -> beforeEach -> @pinyin = require 'util/pinyin' describe 'function: make', -> it 'should make pinyin', -> expect(@pinyin.make('测试')).toEqualImmutable Immutable.fromJS { pinyin: 'ceshi' pinyins: ['ceshi'] py: 'cs' ...
pys: ['ld', 'lt', 'ls', 'ls'] } it 'should make heteronym and make unique', -> expect(@pinyin.make('了了了')).toEqualImmutable Immutable.fromJS { pinyin: 'lelele' pinyins: ['lelele', 'liaolele', 'leliaole', 'liaoliaole', 'leleliao', 'liaoleliao', 'leliaoliao', 'liaoliaoliao'] py: '...
CoffeeScript
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/util/pinyin.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/util/pinyin.spec.coffee
1
43
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:raw_corpus
raw_corpus
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function', (err, resp) -> calls += 1 assert.equal ...
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
cddec8828bb8bafcddb6b494651578e0ef1e5323
542
https://github.com/technoweenie/coffee-resque/blob/cddec8828bb8bafcddb6b494651578e0ef1e5323/test/connection_enqueue_test.coffee
1
44
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'so...
var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.enqueue('my-que...
CoffeeScript
JavaScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
cddec8828bb8bafcddb6b494651578e0ef1e5323
542
https://github.com/technoweenie/coffee-resque/blob/cddec8828bb8bafcddb6b494651578e0ef1e5323/test/connection_enqueue_test.coffee
1
44
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; ...
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function', (err, resp) -> calls += 1 assert.equal ...
JavaScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
cddec8828bb8bafcddb6b494651578e0ef1e5323
542
https://github.com/technoweenie/coffee-resque/blob/cddec8828bb8bafcddb6b494651578e0ef1e5323/test/connection_enqueue_test.coffee
1
44
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:completion
completion
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function', (err, resp) -> calls += 1 assert.equal ...
assert.equal 1, resp conn.redis.rpop conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 data = JSON.parse resp assert.equal 'some-function', data.class assert.deepEqual [], data.args conn.enqueue 'my-queue', 'other-function', ['abc', 1], (err, resp) -> calls += 1 assert.equal 1, resp conn....
CoffeeScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
cddec8828bb8bafcddb6b494651578e0ef1e5323
542
https://github.com/technoweenie/coffee-resque/blob/cddec8828bb8bafcddb6b494651578e0ef1e5323/test/connection_enqueue_test.coffee
1
44
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:raw_corpus
raw_corpus
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0
542
https://github.com/technoweenie/coffee-resque/blob/706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'so...
var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.enqueue('my-que...
CoffeeScript
JavaScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0
542
https://github.com/technoweenie/coffee-resque/blob/706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; ...
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
JavaScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0
542
https://github.com/technoweenie/coffee-resque/blob/706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:completion
completion
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
assert.equal 1, resp conn.redis.rpop conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 data = JSON.parse resp assert.equal 'some-function', data.class assert.deepEqual [], data.args conn.enqueue 'my-queue', 'other-function', ['abc', 1] conn.redis.rpop conn.key('queue', 'my-queue'), (err, resp...
CoffeeScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0
542
https://github.com/technoweenie/coffee-resque/blob/706a6fb8696fc868c8f2587ff7c30a8d5a98d5c0/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:raw_corpus
raw_corpus
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf
542
https://github.com/technoweenie/coffee-resque/blob/6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'so...
var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.enqueue('my-que...
CoffeeScript
JavaScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf
542
https://github.com/technoweenie/coffee-resque/blob/6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var calls, conn; require('./helper'); calls = 0; conn = resque(); conn.redis.scard(conn.key('queues'), function(err, resp) { calls += 1; return assert.equal(0, resp); }); conn.redis.llen(conn.key('queue', 'my-queue'), function(err, resp) { calls += 1; ...
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
JavaScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf
542
https://github.com/technoweenie/coffee-resque/blob/6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf/test/connection_enqueue_test.coffee
1
40
technoweenie/coffee-resque:test/connection_enqueue_test.coffee:1:completion
completion
require './helper' calls = 0 conn = resque() conn.redis.scard conn.key('queues'), (err, resp) -> calls += 1 assert.equal 0, resp conn.redis.llen conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 assert.equal 0, resp conn.enqueue 'my-queue', 'some-function' conn.redis.scard conn.key('queues'), (err, ...
assert.equal 1, resp conn.redis.rpop conn.key('queue', 'my-queue'), (err, resp) -> calls += 1 data = JSON.parse resp assert.equal 'some-function', data.class assert.deepEqual [], data.args conn.enqueue 'my-queue', 'other-function', 'abc', 1 conn.redis.rpop conn.key('queue', 'my-queue'), (err, resp) ...
CoffeeScript
CoffeeScript
technoweenie/coffee-resque
test/connection_enqueue_test.coffee
MIT
6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf
542
https://github.com/technoweenie/coffee-resque/blob/6f9e920cf11dabf7e7ab94ad23585d9bae0d1ccf/test/connection_enqueue_test.coffee
1
40
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:raw_corpus
raw_corpus
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:completion
completion
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
w = new @Widget({ root: ".inputbox" }) w.sendKeys(sent) .then => new @Widget({ root: "p" }) .getValue(".inputbox").should.eventually.eql(read) @When /^I make sure inputbox is empty$/, -> new @Widget({root: ".inputbox"}).then (w) => w.find().then (el) -> el.clear...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:2:raw_corpus
raw_corpus
Driver.Key.SPACE, "send", Driver.Key.SPACE, "keys" ] }).then -> w.getValue({selector: ".inputbox"}) .should.eventually.eql("wow such send keys") @When /^I send keys to an element with multiple arguments I should be able to read them$/, -> new @Widget({ root: "....
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
55
104
mojotech/pioneer:test/integration/steps/widget_steps.coffee:2:completion
completion
Driver.Key.SPACE, "send", Driver.Key.SPACE, "keys" ] }).then -> w.getValue({selector: ".inputbox"}) .should.eventually.eql("wow such send keys") @When /^I send keys to an element with multiple arguments I should be able to read them$/, -> new @Widget({ root: "....
new @Widget({ root: selector }) .removeClass(className) @When /^I toggle class "([^"]*)" on "([^"]*)"$/, (className, selector) -> new @Widget({ root: selector }) .toggleClass(className) @When /^I add class "([^"]*)" to "([^"]*)" in "([^"]*)"$/, (className, childSelector, selector) ...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
55
104
mojotech/pioneer:test/integration/steps/widget_steps.coffee:3:raw_corpus
raw_corpus
className: className, selector: childSelector }) @When /^I toggle class "([^"]*)" on "([^"]*)" in "([^"]*)"$/, (className, childSelector, selector) -> new @Widget({ root: selector }) .toggleClass({ className: className, selector: childSelector }) @Then /^"([^"]*)" shoul...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
105
154
mojotech/pioneer:test/integration/steps/widget_steps.coffee:3:completion
completion
className: className, selector: childSelector }) @When /^I toggle class "([^"]*)" on "([^"]*)" in "([^"]*)"$/, (className, childSelector, selector) -> new @Widget({ root: selector }) .toggleClass({ className: className, selector: childSelector }) @Then /^"([^"]*)" shoul...
@Then /^"([^"]*)" should contain class "([^"]*)" in "([^"]*)"$/, (childSelector, className, selector) => widget = new @Widget({ root: selector }) .hasClass({ className: className selector: childSelector }).should.eventually.be.true @Then /^"([^"]*)" should not contain class "([^"]*)...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
105
154
mojotech/pioneer:test/integration/steps/widget_steps.coffee:4:raw_corpus
raw_corpus
.should.eventually .eql("ok ok only on hover") @Given /^I should be able to double click an element$/, -> new @W({ root: '.double' }) .doubleClick() .then (w) -> w.read() .should.eventually .eql("wow such click") @Given /^I should be able to clear an input$/, -> w...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
155
181
mojotech/pioneer:test/integration/steps/widget_steps.coffee:4:completion
completion
.should.eventually .eql("ok ok only on hover") @Given /^I should be able to double click an element$/, -> new @W({ root: '.double' }) .doubleClick() .then (w) -> w.read() .should.eventually .eql("wow such click")
@Given /^I should be able to clear an input$/, -> w = new @W({ root: ".inputbox" }) w.sendKeys("filled with this").then => w.clear().then (widget) -> widget.getValue().should.eventually.eql("") @When /^I find all div elements in the body tag then I should get a list of them$/, -> ...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
1ff10e1bfce888aa4ede8af8dbdb80e1b0899201
523
https://github.com/mojotech/pioneer/blob/1ff10e1bfce888aa4ede8af8dbdb80e1b0899201/test/integration/steps/widget_steps.coffee
155
181
mojotech/pioneer:test/integration/steps/widget_steps.coffee:4:raw_corpus
raw_corpus
.should.eventually .eql("ok ok only on hover") @Given /^I should be able to double click an element$/, -> new @W({ root: '.double' }) .doubleClick() .then (w) -> w.read() .should.eventually .eql("wow such click") @Given /^I should be able to clear an input$/, -> w...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
08b0895e3f90e3e4ad357cdc35d147203b3fbef3
523
https://github.com/mojotech/pioneer/blob/08b0895e3f90e3e4ad357cdc35d147203b3fbef3/test/integration/steps/widget_steps.coffee
155
174
mojotech/pioneer:test/integration/steps/widget_steps.coffee:4:completion
completion
.should.eventually .eql("ok ok only on hover") @Given /^I should be able to double click an element$/, -> new @W({ root: '.double' }) .doubleClick() .then (w) -> w.read()
.should.eventually .eql("wow such click") @Given /^I should be able to clear an input$/, -> w = new @W({ root: ".inputbox" }) w.sendKeys("filled with this").then => w.clear().then (widget) -> widget.getValue().should.eventually.eql("")
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
08b0895e3f90e3e4ad357cdc35d147203b3fbef3
523
https://github.com/mojotech/pioneer/blob/08b0895e3f90e3e4ad357cdc35d147203b3fbef3/test/integration/steps/widget_steps.coffee
155
174
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:raw_corpus
raw_corpus
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(...
module.exports = function() { this.When(/^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, function(child, root, isPresent) { return this.Widget.find({ root: root }).then(function(widget) { return widget.isPresent(child); }).then(function(present) { return expect(...
CoffeeScript
JavaScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = function() { this.When(/^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, function(child, root, isPresent) { return this.Widget.find({ root: root }).then(function(widget) { return widget.isPresent(child...
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
JavaScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:completion
completion
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
root: "p" }) .getValue(".inputbox").should.eventually.eql(read) @When /^I make sure inputbox is empty$/, -> new @Widget({root: ".inputbox"}).then (w) => w.find().then (el) -> el.clear() @Then /^I send keys to an element with an object I should be able to read them$/, -> w = new @Widget({...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
5
54
mojotech/pioneer:test/integration/steps/widget_steps.coffee:2:raw_corpus
raw_corpus
.should.eventually.eql("wow such send keys") @When /^I add class "([^"]*)" to "([^"]*)"$/, (className, selector) -> new @Widget({ root: selector }) .addClass(className) @Then /^"([^"]*)" should have class "([^"]*)"$/, (selector, expected) -> new @Widget({ root: selector }) .get...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
55
104
mojotech/pioneer:test/integration/steps/widget_steps.coffee:2:completion
completion
.should.eventually.eql("wow such send keys") @When /^I add class "([^"]*)" to "([^"]*)"$/, (className, selector) -> new @Widget({ root: selector }) .addClass(className) @Then /^"([^"]*)" should have class "([^"]*)"$/, (selector, expected) -> new @Widget({ root: selector }) .get...
}) .getAttribute('class') .then (attribute) -> attribute.indexOf(expected).should.eql(-1) @When /^I toggle class "([^"]*)" on "([^"]*)"$/, (className, selector) -> new @Widget({ root: selector }) .toggleClass(className) @When /^I add class "([^"]*)" to "([^"]*)" in "([^"]*)"$/, (cl...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
530affaa4ed7c3718c2c29d93a5a692e4d97b8d7
523
https://github.com/mojotech/pioneer/blob/530affaa4ed7c3718c2c29d93a5a692e4d97b8d7/test/integration/steps/widget_steps.coffee
55
104
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:raw_corpus
raw_corpus
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
40d78cbe8f85d6d0cf5d876956576708379f820e
523
https://github.com/mojotech/pioneer/blob/40d78cbe8f85d6d0cf5d876956576708379f820e/test/integration/steps/widget_steps.coffee
4
53
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(...
module.exports = function() { this.When(/^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, function(child, root, isPresent) { return this.Widget.find({ root: root }).then(function(widget) { return widget.isPresent(child); }).then(function(present) { return expect(...
CoffeeScript
JavaScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
40d78cbe8f85d6d0cf5d876956576708379f820e
523
https://github.com/mojotech/pioneer/blob/40d78cbe8f85d6d0cf5d876956576708379f820e/test/integration/steps/widget_steps.coffee
4
53
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = function() { this.When(/^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, function(child, root, isPresent) { return this.Widget.find({ root: root }).then(function(widget) { return widget.isPresent(child...
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
JavaScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
40d78cbe8f85d6d0cf5d876956576708379f820e
523
https://github.com/mojotech/pioneer/blob/40d78cbe8f85d6d0cf5d876956576708379f820e/test/integration/steps/widget_steps.coffee
4
53
mojotech/pioneer:test/integration/steps/widget_steps.coffee:1:completion
completion
module.exports = -> @When /^I see if "([^"]*)" is present within "([^"]*)" I should get "([^"]*)"$/, (child, root, isPresent) -> @Widget.find({ root: root }).then((widget) -> widget.isPresent(child) ) .then (present) -> expect(""+present).to.eql(isPresent) @When /^I see if "([^"]*...
@When /^I add class "([^"]*)" to "([^"]*)"$/, (className, selector) -> new @Widget({ root: selector }) .addClass(className) @Then /^"([^"]*)" should have class "([^"]*)"$/, (selector, expected) -> new @Widget({ root: selector }) .getAttribute('class') .then (attribute) -> ...
CoffeeScript
CoffeeScript
mojotech/pioneer
test/integration/steps/widget_steps.coffee
MIT
40d78cbe8f85d6d0cf5d876956576708379f820e
523
https://github.com/mojotech/pioneer/blob/40d78cbe8f85d6d0cf5d876956576708379f820e/test/integration/steps/widget_steps.coffee
4
53