Skip to content

Commit

Permalink
Merge #650. Update History.md
Browse files Browse the repository at this point in the history
Also remove obsolete comment from the Clojure backend.
  • Loading branch information
brasmusson committed Jan 26, 2014
2 parents 58e57b0 + 5e3d2fd commit 63dca60
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 51 deletions.
1 change: 1 addition & 0 deletions History.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## [1-1-6-SNAPSHOT (Git master)](https://github.com/cucumber/cucumber-jvm/compare/v1.1.5...master)

* [Clojure] Fixed bug in the snippet generation that caused an exception. ([#650](https://github.com/cucumber/cucumber-jvm/pull/650) shaolang)
* [Core] More precise handling of the XStream errors. ([#657](https://github.com/cucumber/cucumber-jvm/issues/657), [#658](https://github.com/cucumber/cucumber-jvm/pull/658) Mykola Gurov)
* [Core] Performance improvement: URLOutputStream can write several bytes, not just one-by-one. ([#654](https://github.com/cucumber/cucumber-jvm/issues/654) Aslak Hellesøy)
* [Core] Add support for transposed tables. ([#382](https://github.com/cucumber/cucumber-jvm/issues/382), [#635](https://github.com/cucumber/cucumber-jvm/pull/635), Roberto Lo Giacco)
Expand Down
5 changes: 2 additions & 3 deletions clojure/src/main/clj/cucumber/runtime/clj.clj
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@

(def glue (atom nil))

;; Make sure ClojureSnippet.java is in sync with this - for testing purposes.
(defn clojure-snippet []
(reify
Snippet
Expand Down Expand Up @@ -57,8 +56,8 @@

(defn- -disposeWorld [cljb])

(defn- -getSnippet [cljb step]
(.getSnippet snippet-generator step))
(defn- -getSnippet [cljb step _]
(.getSnippet snippet-generator step nil))

(defn- -setUnreportedStepExecutor [cljb executor]
"executor")
Expand Down
45 changes: 0 additions & 45 deletions clojure/src/test/java/cucumber/runtime/clojure/ClojureSnippet.java

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package cucumber.runtime.clojure;

import cucumber.runtime.snippets.SnippetGenerator;
import cucumber.runtime.clj.Backend;
import gherkin.formatter.model.Comment;
import gherkin.formatter.model.DataTableRow;
import gherkin.formatter.model.Step;
Expand All @@ -18,7 +18,7 @@ public class ClojureSnippetTest {
@Test
public void generatesPlainSnippet() {
Step step = new Step(NO_COMMENTS, "Given ", "I have 4 cukes in my \"big\" belly", 0, null, null);
String snippet = new SnippetGenerator(new ClojureSnippet()).getSnippet(step, null);
String snippet = (new Backend(null)).getSnippet(step, null);
String expected = "" +
"(Given #\"^I have (\\d+) cukes in my \\\"([^\\\"]*)\\\" belly$\" [arg1 arg2]\n" +
" (comment Write code here that turns the phrase above into concrete actions )\n" +
Expand All @@ -30,7 +30,7 @@ public void generatesPlainSnippet() {
public void generatesSnippetWithDataTable() {
List<DataTableRow> dataTable = asList(new DataTableRow(NO_COMMENTS, asList("col1"), 1));
Step step = new Step(NO_COMMENTS, "Given ", "I have:", 0, dataTable, null);
String snippet = new SnippetGenerator(new ClojureSnippet()).getSnippet(step, null);
String snippet = (new Backend(null)).getSnippet(step, null);
String expected = "" +
"(Given #\"^I have:$\" [arg1]\n" +
" (comment Write code here that turns the phrase above into concrete actions )\n" +
Expand Down

0 comments on commit 63dca60

Please sign in to comment.