Fewer parentheses

This commit is contained in:
Vit Brunner
2014-12-22 23:07:40 +01:00
parent 83fbe5d538
commit fe8c134920
17 changed files with 100 additions and 108 deletions
@@ -1,18 +1,18 @@
factory = {}
module "reader factory", {
setup: () ->
setup: ->
factory = getInjector().get 'readerFactory'
}
test "reads markdown", () ->
test "reads markdown", ->
ok factory "somefile.md"
ok factory "otherfile.markdown"
test "reads json", () ->
test "reads json", ->
ok factory "fried.json"
test "doesn't read doc", () ->
throws () ->
test "doesn't read doc", ->
throws ->
factory "microsoft.doc"
, /unknown/i
+2 -2
View File
@@ -1,11 +1,11 @@
reader = {}
module "json reader", {
setup: () ->
setup: ->
reader = getInjector().get 'jsonReader'
}
test "loads poem", () ->
test "loads poem", ->
deepEqual reader("""
{
meta: {
@@ -1,11 +1,11 @@
reader = {}
module "markdown reader", {
setup: () ->
setup: ->
reader = getInjector().get 'markdownReader'
}
test "loads poem with section numbers, paragraphs, and a list", () ->
test "loads poem with section numbers, paragraphs, and a list", ->
deepEqual reader("""
Title: Universal Declaration of Human Rights
Author: John Peters Humphrey
@@ -57,7 +57,7 @@ test "loads poem with section numbers, paragraphs, and a list", () ->
]
}
test "loads poem with leading text and mixed separators", () ->
test "loads poem with leading text and mixed separators", ->
deepEqual reader("""
Title: Test leading text and mixed separators
@@ -79,7 +79,7 @@ test "loads poem with leading text and mixed separators", () ->
]
}
test "loads poem using a custom separator", () ->
test "loads poem using a custom separator", ->
deepEqual reader("""
Title: Separator test
Separator: heading