language-puppet 1.4.6.4 → 1.4.6.5
raw patch · 5 files changed
+22/−4 lines, 5 filesdep ~directory
Dependency ranges changed: directory
Files
- language-puppet.cabal +5/−1
- tests/HieraSpec.hs +2/−3
- tests/hiera/misc/config/hiera.yaml +8/−0
- tests/hiera/misc/data/common.yaml +4/−0
- tests/hiera/misc/production.yaml +3/−0
language-puppet.cabal view
@@ -2,7 +2,7 @@ -- documentation, see http://haskell.org/cabal/users-guide/ name: language-puppet-version: 1.4.6.4+version: 1.4.6.5 synopsis: Tools to parse and evaluate the Puppet DSL. description: This is a set of tools that is supposed to fill all your Puppet needs : syntax checks, catalog compilation, PuppetDB queries, simulation of complex interactions between nodes, Puppet master replacement, and more ! homepage: http://lpuppet.banquise.net/@@ -26,6 +26,9 @@ tests/hiera/interpolate/config/*.yaml tests/hiera/interpolate/data/*.yaml tests/hiera/*.com.json+ tests/hiera/misc/*.yaml+ tests/hiera/misc/config/*.yaml+ tests/hiera/misc/data/*.yaml tests/Parser/lexer/*.pp Data-Files:@@ -148,6 +151,7 @@ default-extensions: OverloadedStrings, NoImplicitPrelude, FlexibleContexts, LambdaCase default-language: Haskell2010 build-depends: base+ , directory , Glob , hslogger , hspec >= 2.0 && < 3.0
tests/HieraSpec.hs view
@@ -16,7 +16,7 @@ checkFail :: (Show a) => Either rr a -> Expectation checkFail (Right v) = expectationFailure ("Should have failed, but returned: " ++ show v)-checkFail _ = return ()+checkFail _ = return () fqdn :: Text fqdn = "node.com"@@ -195,7 +195,7 @@ it "split sq" $ varSplitter "'ab'" `shouldBe` HieraVar ("ab" :| []) it "split sq 2" $ varSplitter "'ab.cd'" `shouldBe` HieraVar ("ab.cd" :| []) it "split sq 2 mixed" $ varSplitter "'ab.cd'.ef" `shouldBe` HieraVar ("ab.cd" :| ["ef"])- it "split sq 2 mixed 4" $ varSplitter "'ab.cd'.ef.'lol.cat'.bar" `shouldBe` + it "split sq 2 mixed 4" $ varSplitter "'ab.cd'.ef.'lol.cat'.bar" `shouldBe` HieraVar ("ab.cd" :| ["ef", "lol.cat", "bar"]) it "split all mixed" $ varSplitter "'a.b'.\"c.d\".e.f" `shouldBe` HieraVar ("a.b" :| ["c.d", "e", "f"])@@ -247,4 +247,3 @@ q mempty "ipl_key" QFirst >>= checkFail it "should not find a subkey that is matched within a string" $ q mempty "key.subkey" QFirst >>= checkFail-
+ tests/hiera/misc/config/hiera.yaml view
@@ -0,0 +1,8 @@+:backends:+ - yaml++:hierarchy:+ - common++:yaml:+ :datadir: '../data'
+ tests/hiera/misc/data/common.yaml view
@@ -0,0 +1,4 @@+---++foo: bar+literal: "%{literal('%')}{SERVER_NAME}"
+ tests/hiera/misc/production.yaml view
@@ -0,0 +1,3 @@+---+foo: bar+