-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Make links in annotations clickable * Update test script and bindata.go * Add target = _blank
- Loading branch information
Showing
6 changed files
with
87 additions
and
5 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,23 @@ | ||
module StringUtils exposing (testLinkify) | ||
|
||
import Utils.String exposing (linkify) | ||
import Test exposing (..) | ||
import Expect | ||
|
||
|
||
testLinkify : Test | ||
testLinkify = | ||
describe "linkify" | ||
[ test "should linkify a url in the middle" <| | ||
\() -> | ||
Expect.equal (linkify "word1 http://url word2") | ||
[ Err "word1 ", Ok "http://url", Err " word2" ] | ||
, test "should linkify a url in the beginning" <| | ||
\() -> | ||
Expect.equal (linkify "http://url word1 word2") | ||
[ Ok "http://url", Err " word1 word2" ] | ||
, test "should linkify a url in the end" <| | ||
\() -> | ||
Expect.equal (linkify "word1 word2 http://url") | ||
[ Err "word1 word2 ", Ok "http://url" ] | ||
] |
Large diffs are not rendered by default.
Oops, something went wrong.