Skip to content

Updates for 0.12 #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 19, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
language: node_js
sudo: false
sudo: true
node_js:
- "5.5"
- 10
env:
- PATH=$HOME/purescript:$PATH
install:
- wget -O $HOME/purescript.tar.gz https://github.com/purescript/purescript/releases/download/v0.11.6/linux64.tar.gz
- wget -O $HOME/purescript.tar.gz https://github.com/purescript/purescript/releases/download/v0.12.0/linux64.tar.gz
- tar -xvf $HOME/purescript.tar.gz -C $HOME/
- chmod a+x $HOME/purescript
- npm install -g bower pulp@^11.0.0
- npm install -g bower pulp@^12.3.0
- bower install
script:
- travis_wait pulp build
- travis_wait pulp test
- pulp build
- pulp test

cache:
directories:
Expand Down
10 changes: 5 additions & 5 deletions bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,10 @@
"output"
],
"dependencies": {
"purescript-prelude": "^3.0.0",
"purescript-eff": "^3.1.0",
"purescript-arrays": "^4.0.0",
"purescript-spec": "^2.0.0",
"purescript-node-fs": "^4.0.0"
"purescript-prelude": "^4.0.0",
"purescript-effect": "^2.0.0",
"purescript-arrays": "^5.0.0",
"purescript-spec": "^3.0.0",
"purescript-node-fs": "^5.0.0"
}
}
14 changes: 7 additions & 7 deletions src/Test/Spec/Discovery.purs
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
module Test.Spec.Discovery (discover) where

import Prelude
import Control.Monad.Eff (Eff)

import Data.Traversable (sequence_)
import Node.FS (FS)
import Effect (Effect)
import Test.Spec (Spec)

foreign import getSpecs :: forall r. String
-> Eff (fs :: FS | r) (Array (Spec (fs :: FS | r) Unit))
foreign import getSpecs :: String
-> Effect (Array (Spec Unit))

discover :: forall r. String
-> Eff (fs :: FS | r) (Spec (fs :: FS | r) Unit)
discover pattern = getSpecs pattern >>= (pure <<< sequence_)
discover :: String
-> Effect (Spec Unit)
discover pattern = getSpecs pattern >>= (pure <<< sequence_)
8 changes: 4 additions & 4 deletions test/Main.purs
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
module Test.Main where

import Prelude
import Control.Monad.Eff (Eff)
import Node.FS (FS)

import Effect (Effect)
import Test.Spec.Discovery (discover)
import Test.Spec.Reporter.Console (consoleReporter)
import Test.Spec.Runner (RunnerEffects, run)
import Test.Spec.Runner (run)

main :: Eff (RunnerEffects (fs :: FS)) Unit
main :: Effect Unit
main = discover "Test\\.Spec\\.Discovery.*Spec" >>= run [consoleReporter]
2 changes: 1 addition & 1 deletion test/Test/Spec/Discovery2Spec.purs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module Test.Spec.Discovery2Spec where
import Prelude
import Test.Spec (Spec, describe, it)

spec :: forall r. Spec r Unit
spec :: Spec Unit
spec =
describe "discovery" do
it "discovers the specs again in this project" $ pure unit
2 changes: 1 addition & 1 deletion test/Test/Spec/DiscoverySpec.purs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module Test.Spec.DiscoverySpec where
import Prelude
import Test.Spec (Spec, describe, it)

spec :: forall r. Spec r Unit
spec :: Spec Unit
spec =
describe "discovery" do
it "discovers the specs in this project" $ pure unit