-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #24 from e-bigmoon/yesodroute-testcase
Yesodroute testcase
- Loading branch information
Showing
9 changed files
with
154 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
-- SYNTAX TEST "source.yesod.routes" "attribute" | ||
|
||
/admin AdminR !admin: | ||
-- <-------------- - entity.other.attribute-name | ||
-- ^^^^^^ entity.other.attribute-name | ||
/1 Admin1R GET !1 | ||
-- ^^^^^^^^^^^^^^^ - entity.other.attribute-name | ||
-- ^^ entity.other.attribute-name | ||
/2 Admin2R GET !2 | ||
-- ^^^^^^^^^^^^^^^ - entity.other.attribute-name | ||
-- ^^ entity.other.attribute-name | ||
/3 Admin3R GET !3 | ||
-- ^^^^^^^^^^^^^^^ - entity.other.attribute-name | ||
-- ^^ entity.other.attribute-name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
-- SYNTAX TEST "source.yesod.routes" "comment line" | ||
|
||
-- comment | ||
-- <-- - comment.line | ||
-- ^^^^^^^^^^ comment.line | ||
|
||
/ HomeR GET-- comment | ||
-- <--------------------------- - comment.line | ||
-- ^^^^^^^^^^ comment.line |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
-- SYNTAX TEST "source.yesod.routes" "handler" | ||
|
||
/foo1 Foo1R GET | ||
-- <-------------- - constant.other.handler | ||
-- ^^^^^ constant.other.handler | ||
-- ^^^^^^^^ - constant.other.handler | ||
/foo2 Foo2R HEAD | ||
-- <-------------- - constant.other.handler | ||
-- ^^^^^ constant.other.handler | ||
-- ^^^^^^^^^ - constant.other.handler | ||
/multi MultiR GET POST | ||
-- <-------------- - constant.other.handler | ||
-- ^^^^^^ constant.other.handler | ||
-- ^^^^^^^^^^^^ - constant.other.handler | ||
/blog/#BlogId BlogPostR GET POST | ||
-- <-------------- - constant.other.handler | ||
-- ^^^^^^^^^ constant.other.handler | ||
-- ^^^^^^^^^ - constant.other.handler |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
-- SYNTAX TEST "source.yesod.routes" "http methods" | ||
|
||
/foo1 Foo1R GET | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo2 Foo2R HEAD | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo3 Foo3R POST | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo4 Foo4R PUT | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo5 Foo5R DELETE | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo6 Foo6R OPTIONS | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/foo7 Foo7R PATCH | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ entity.name.function | ||
/multi MultiR GET POST | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ ^^^^ entity.name.function | ||
/blog/#BlogId BlogPostR GET POST | ||
-- <------------------------ - entity.name.function | ||
-- ^^^ ^^^^ entity.name.function |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
-- SYNTAX TEST "source.yesod.routes" "pattern" | ||
|
||
/foo/bar Foo1R GET | ||
-- <-------------------- - support.type.patterns | ||
/foo/#Text Foo2R GET | ||
-- <----- - support.type.patterns | ||
-- ^^^^^ support.type.patterns | ||
-- ^^^^^^^^^^ - support.type.patterns | ||
/foo/bar Foo1R GET | ||
!/foo/#Int Foo2R GET | ||
-- <------ - support.type.patterns | ||
-- ^^^^ support.type.patterns | ||
-- ^^^^^^^^^^^ - support.type.patterns | ||
!/foo/#Text Foo3R GET | ||
-- <------ - support.type.patterns | ||
-- ^^^^^ support.type.patterns | ||
-- ^^^^^^^^^^ - support.type.patterns |