From aae6fb7f6b1b28597acaa4396fd152b3247cb6c8 Mon Sep 17 00:00:00 2001 From: Son Truong Date: Thu, 11 Jun 2015 14:52:30 -0700 Subject: [PATCH 1/5] first test --- index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/index.js b/index.js index 9bb9cd7..f5f9521 100644 --- a/index.js +++ b/index.js @@ -1,4 +1,5 @@ var doubler = function(a, b) { + return (a * 2) + (b*2) } console.assert(doubler(4,2) === 12); From 14444c7120bad88fe7d8abece84bf4d8d92b554c Mon Sep 17 00:00:00 2001 From: Son Truong Date: Thu, 11 Jun 2015 15:08:25 -0700 Subject: [PATCH 2/5] merge --- index.js | 4 ---- 1 file changed, 4 deletions(-) diff --git a/index.js b/index.js index 9fa843d..b695df7 100644 --- a/index.js +++ b/index.js @@ -1,9 +1,5 @@ var doubler = function(a, b) { -<<<<<<< HEAD - return (a * 2) + (b*2) -======= return 2 * a + 2 * b; ->>>>>>> 76d7cc298de71b7fe2e0dc4fa35830d61ce54a3b } console.assert(doubler(4,2) === 12); From 7fae5bffcbc086f0140bd837337efd99c15c50a6 Mon Sep 17 00:00:00 2001 From: Son Truong Date: Thu, 11 Jun 2015 15:12:58 -0700 Subject: [PATCH 3/5] 2nd test --- index.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index e73f17c..4ee0df1 100644 --- a/index.js +++ b/index.js @@ -1,7 +1,10 @@ var doubler = function(a, b) { - return 2 * a + 2 * b; + return a + a + b + b; } + + + console.assert(doubler(4,2) === 12); console.assert(doubler(1,3) === 8); console.assert(doubler(-1,3) === 4); From c655e40a794ba1cb5dea77d56c9801a422a25286 Mon Sep 17 00:00:00 2001 From: Son Truong Date: Thu, 11 Jun 2015 15:28:27 -0700 Subject: [PATCH 4/5] . --- index.js | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/index.js b/index.js index 3f2a06f..b29b472 100644 --- a/index.js +++ b/index.js @@ -1,18 +1,12 @@ var doubler = function(a, b) { - return a + a + b + b; + console.log(a + a + b + b) } -console.assert(doubler(4,2) === 12); -console.assert(doubler(1,3) === 8); -console.assert(doubler(-1,3) === 4); - -console.assert(doubler("a", "b") === "aabb"); -console.assert(doubler("coding", "rocks") === "codingcodingrocksrocks"); function m3() { return 3; } function m4() { return 4; } function m2() { return 2; } function m1() { return 1; } -console.assert(doubler(m4, m2) === 12); -console.assert(doubler(m1, m3) === 8); +(doubler(m4, m2) === 12); +(doubler(m1, m3) === 8); From b90fd530fb9326fe32866a6d31c4f56f0697e84d Mon Sep 17 00:00:00 2001 From: Son Truong Date: Thu, 11 Jun 2015 17:38:58 -0700 Subject: [PATCH 5/5] made up TDD challenge --- tdd2.js | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 tdd2.js diff --git a/tdd2.js b/tdd2.js new file mode 100644 index 0000000..abe4235 --- /dev/null +++ b/tdd2.js @@ -0,0 +1,7 @@ +function decode() { + +} + + +console.assert(decode("Ci", "on", "dg"), === "coding") +console.assert(decode(29,53,20) === 252930)