diff options
| author | Eugen Wissner <belka@caraus.de> | 2023-09-22 07:33:02 +0200 |
|---|---|---|
| committer | Eugen Wissner <belka@caraus.de> | 2023-09-22 07:33:02 +0200 |
| commit | 840290491f45157249ba97fb8f5e4cae9e04dc90 (patch) | |
| tree | 0bc54eb0aa3ec248145e725ec963c81c045f586c /tests/SlackBuilder | |
| parent | a7114618c1290b00745db69ef0e60b2e848a662d (diff) | |
| download | slackbuilder-840290491f45157249ba97fb8f5e4cae9e04dc90.tar.gz | |
Split the code into library and application
Diffstat (limited to 'tests/SlackBuilder')
| -rw-r--r-- | tests/SlackBuilder/PackageSpec.hs | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/tests/SlackBuilder/PackageSpec.hs b/tests/SlackBuilder/PackageSpec.hs index d8617a4..82d9a87 100644 --- a/tests/SlackBuilder/PackageSpec.hs +++ b/tests/SlackBuilder/PackageSpec.hs @@ -2,7 +2,17 @@ module SlackBuilder.PackageSpec ( spec ) where -import Test.Hspec (Spec) +import SlackBuilder.Package +import Test.Hspec (Spec, describe, it, shouldBe) +import Text.URI.QQ (uri) spec :: Spec -spec = pure () +spec = do + describe "renderDownloadWithVersion" $ + it "renders text as URL" $ + let given = DownloadTemplate + $ pure + $ StaticPlaceholder "https://example.com" + actual = renderDownloadWithVersion given "1.2" + expected = Just [uri|https://example.com|] + in actual `shouldBe` expected |
