mirror of
https://github.com/correl/elm.git
synced 2024-11-15 19:19:31 +00:00
Merge pull request #139 from zwilias/master
Update tests format for elm-test 0.18.3 (#138)
This commit is contained in:
commit
b267bb3f8e
127 changed files with 815 additions and 1842 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -7,3 +7,4 @@ elm-stuff
|
||||||
CHECKLIST
|
CHECKLIST
|
||||||
build.js
|
build.js
|
||||||
node_modules
|
node_modules
|
||||||
|
build
|
||||||
|
|
21
.travis.yml
21
.travis.yml
|
@ -4,10 +4,29 @@ language: bash
|
||||||
|
|
||||||
sudo: false
|
sudo: false
|
||||||
|
|
||||||
|
before_install:
|
||||||
|
- echo -e "Host github.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
|
||||||
|
- | # epic build time improvement - see https://github.com/elm-lang/elm-compiler/issues/1473#issuecomment-245704142
|
||||||
|
if [ ! -d sysconfcpus/bin ];
|
||||||
|
then
|
||||||
|
git clone https://github.com/obmarg/libsysconfcpus.git;
|
||||||
|
cd libsysconfcpus;
|
||||||
|
./configure --prefix=$TRAVIS_BUILD_DIR/sysconfcpus;
|
||||||
|
make && make install;
|
||||||
|
cd ..;
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- nvm install 6
|
- nvm install 6
|
||||||
- nvm use 6
|
- nvm use 6
|
||||||
- npm install
|
- npm install
|
||||||
|
- if [ ! -f node_modules/.bin/elm-make-old ];
|
||||||
|
then
|
||||||
|
mv node_modules/.bin/elm-make node_modules/.bin/elm-make-old;
|
||||||
|
printf '%s\n\n' '#!/bin/bash' 'echo "Running elm-make with sysconfcpus -n 2"' '$TRAVIS_BUILD_DIR/sysconfcpus/bin/sysconfcpus -n 2 elm-make-old "$@"' > $(npm config get prefix)/bin/elm-make;
|
||||||
|
chmod +x $(npm config get prefix)/bin/elm-make;
|
||||||
|
fi
|
||||||
- bin/install-elm-format linux
|
- bin/install-elm-format linux
|
||||||
- export PATH=$PATH:$PWD/bin
|
- export PATH=$PATH:$PWD/bin
|
||||||
|
|
||||||
|
@ -18,5 +37,5 @@ script:
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- node_modules
|
|
||||||
- elm-stuff
|
- elm-stuff
|
||||||
|
- sysconfcpus
|
||||||
|
|
29
README.md
29
README.md
|
@ -10,10 +10,9 @@ The simplest way to install Elm is via Node.js/NPM.
|
||||||
If you don't already have Node.js installed on your computer, you can download it from [the official site](https://nodejs.org/). Once you have Node.js up and running, follow these steps to install the Elm platform and elm-test.
|
If you don't already have Node.js installed on your computer, you can download it from [the official site](https://nodejs.org/). Once you have Node.js up and running, follow these steps to install the Elm platform and elm-test.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
$ npm install --global elm elm-test
|
$ npm install
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
Thank you so much for contributing! :tada:
|
Thank you so much for contributing! :tada:
|
||||||
|
@ -41,28 +40,26 @@ Please keep the following in mind:
|
||||||
- Please do not add a README or README.md file to the exercise directory. The READMEs are constructed using shared metadata, which lives in the
|
- Please do not add a README or README.md file to the exercise directory. The READMEs are constructed using shared metadata, which lives in the
|
||||||
[exercism/x-common](https://github.com/exercism/x-common) repository.
|
[exercism/x-common](https://github.com/exercism/x-common) repository.
|
||||||
|
|
||||||
- Each exercise should have a test suite, an example solution, a template file for the real implementation and an `elm-package.json` file with the `elm-test` and `elm-console` dependencies. The CI build expects files to be named using the following convention. The example solution should be named `ExerciseModuleName.example`. The template file should be named `ExerciseModuleName.elm`. Test file should be named `ExerciseModuleNameTest.elm`.
|
- Each exercise should have a test suite, an example solution, a template file for the real implementation and an `elm-package.json` file with the `elm-test` and `elm-console` dependencies. The CI build expects files to be named using the following convention. The example solution should be named `ExerciseModuleName.example`. The template file should be named `ExerciseModuleName.elm`. Test file should be named `Tests.elm`.
|
||||||
|
|
||||||
- The recommended workflow when working on an exercise is to first create the implementation and test files, `ExerciseModuleName.elm` and `ExerciseModuleNameTest.elm`.
|
- The recommended workflow when working on an exercise is to first create the implementation and test files, `ExerciseModuleName.elm` and `tests/Tests.elm`. You'll likely want to copy one of the existing exercise directories as a quick start.
|
||||||
- Test the new exercise directly by running `elm-test exercises/exercise_module_name/ExerciseModuleNameTest.elm`.
|
- Test the new exercise directly by running `npm test` from the exercise directory.
|
||||||
|
|
||||||
- Once the implementation of the exercise is complete, move `ExerciseModuleName.elm` to `ExerciseModuleName.example` and create the template file.
|
- Once the implementation of the exercise is complete, rename `ExerciseModuleName.elm` to `ExerciseModuleName.example.elm` and create the template `ExerciseModuleName.elm`.
|
||||||
|
|
||||||
- Make sure everything is good to go by running all tests with `bin/build.sh`.
|
- Make sure everything is good to go by running all tests with `bin/build.sh`.
|
||||||
|
|
||||||
- If you have [elm-format](https://github.com/avh4/elm-format) installed, you can easily check the project by running `WITH_FORMAT=true bin/build.sh`. If you get diffs on exercises other than the one you are working on, please submit a separate pull request.
|
|
||||||
|
|
||||||
- Please do not commit any Elm configuration files or directories inside the exercise, such as `elm-stuff`. Please include only the standard `elm-package.json`.
|
- Please do not commit any Elm configuration files or directories inside the exercise, such as `elm-stuff`. Please include only the standard `elm-package.json`.
|
||||||
|
|
||||||
- Test files should use the following format:
|
- Test files should use the following format:
|
||||||
|
|
||||||
```elm
|
```elm
|
||||||
port module Main exposing (..)
|
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run)
|
module Tests exposing (..)
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
|
import ExerciseModuleName
|
||||||
|
|
||||||
|
|
||||||
tests : Test
|
tests : Test
|
||||||
|
@ -77,19 +74,11 @@ tests =
|
||||||
False
|
False
|
||||||
|> Expect.equal False
|
|> Expect.equal False
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : Program Value
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
||||||
```
|
```
|
||||||
|
|
||||||
- All the tests for xElm exercises can be run from the top level of the repo with `bin/build.sh`. Please run this command before submitting your PR.
|
- All the tests for xElm exercises can be run from the top level of the repo with `bin/build.sh`. Please run this command before submitting your PR.
|
||||||
|
|
||||||
- If you are submitting a new exercise, be sure to add it to the appropriate place in the `config.json` and `elm-package.json` files. Also, please run `bin/fetch-configlet && bin/configlet` to ensure the exercise is configured correctly.
|
- If you are submitting a new exercise, be sure to add it to the appropriate place in the `config.json` file. Also, please run `bin/fetch-configlet && bin/configlet` to ensure the exercise is configured correctly.
|
||||||
|
|
||||||
## License
|
## License
|
||||||
|
|
||||||
|
|
33
bin/build.sh
33
bin/build.sh
|
@ -5,14 +5,12 @@
|
||||||
echo '-------------------------------------------------------'
|
echo '-------------------------------------------------------'
|
||||||
echo "Checking Formatting"
|
echo "Checking Formatting"
|
||||||
|
|
||||||
which elm-format > /dev/null
|
if [ ! -f "bin/elm-format" ]; then
|
||||||
|
echo "Installing local copy of elm-format"
|
||||||
if [ $? -ne 0 ]; then
|
bin/install-elm-format
|
||||||
echo "elm-format not found"
|
|
||||||
exit 1
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
elm-format --yes --validate exercises/**/{*.example.elm,Tests.elm}
|
bin/elm-format --yes --validate exercises/**/*.example.elm exercises/**/tests/Tests.elm
|
||||||
|
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
echo "*******************************************************************"
|
echo "*******************************************************************"
|
||||||
|
@ -24,39 +22,38 @@ if [ $? -ne 0 ]; then
|
||||||
echo "*******************************************************************"
|
echo "*******************************************************************"
|
||||||
exit 1
|
exit 1
|
||||||
else
|
else
|
||||||
echo "formatting looks good!"
|
echo "Formatting looks good!"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# TEST
|
# TEST
|
||||||
|
|
||||||
declare -i TEST_RESULT=0
|
declare -i TEST_RESULT=0
|
||||||
FAILED_EXERCISES=''
|
FAILED_EXERCISES=''
|
||||||
|
|
||||||
|
mkdir -p build/tests
|
||||||
|
|
||||||
for example_file in exercises/**/*.example.elm
|
for example_file in exercises/**/*.example.elm
|
||||||
do
|
do
|
||||||
|
# clean up generated code from last run
|
||||||
|
rm -rf build/tests/elm-stuff/generated-code/
|
||||||
|
|
||||||
exercise_dir=$(dirname $example_file)
|
exercise_dir=$(dirname $example_file)
|
||||||
exercise_name=$(basename $example_file .example.elm)
|
exercise_name=$(basename $example_file .example.elm)
|
||||||
mv "$exercise_dir/$exercise_name.elm" "$exercise_dir/$exercise_name.impl"
|
cp "$exercise_dir/$exercise_name.example.elm" "build/$exercise_name.elm"
|
||||||
mv "$exercise_dir/$exercise_name.example.elm" "$exercise_dir/$exercise_name.elm"
|
cp "$exercise_dir/tests/elm-package.json" build/tests/
|
||||||
|
cp "$exercise_dir/tests/Tests.elm" build/tests/
|
||||||
|
|
||||||
echo '-------------------------------------------------------'
|
echo '-------------------------------------------------------'
|
||||||
echo "Testing $exercise_name"
|
echo "Testing $exercise_name"
|
||||||
|
|
||||||
# prevent elm-test from installing dependencies
|
|
||||||
mv $exercise_dir/elm-package.json $exercise_dir/elm-package.json.disabled
|
|
||||||
|
|
||||||
npm test -- $exercise_dir/Tests.elm
|
npm test -- build/tests/Tests.elm
|
||||||
|
|
||||||
# capture result from last command (elm-test)
|
# capture result from last command (elm-test)
|
||||||
if [ $? -ne 0 ]; then
|
if [ $? -ne 0 ]; then
|
||||||
TEST_RESULT=1
|
TEST_RESULT=1
|
||||||
FAILED_EXERCISES+="$exercise_name\n"
|
FAILED_EXERCISES+="$exercise_name\n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# be kind, rewind
|
|
||||||
mv $exercise_dir/elm-package.json.disabled $exercise_dir/elm-package.json
|
|
||||||
mv "$exercise_dir/$exercise_name.elm" "$exercise_dir/$exercise_name.example.elm"
|
|
||||||
mv "$exercise_dir/$exercise_name.impl" "$exercise_dir/$exercise_name.elm"
|
|
||||||
done
|
done
|
||||||
|
|
||||||
if [ $TEST_RESULT -ne 0 ]; then
|
if [ $TEST_RESULT -ne 0 ]; then
|
||||||
|
|
334
config.json
334
config.json
|
@ -1,169 +1,169 @@
|
||||||
{
|
{
|
||||||
"slug": "elm",
|
"slug": "elm",
|
||||||
"language": "Elm",
|
"language": "Elm",
|
||||||
"repository": "https://github.com/exercism/xelm",
|
"repository": "https://github.com/exercism/xelm",
|
||||||
"active": true,
|
"active": true,
|
||||||
"exercises": [
|
"exercises": [
|
||||||
{
|
{
|
||||||
"slug": "hello-world",
|
"slug": "hello-world",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "bob",
|
"slug": "bob",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "leap",
|
"slug": "leap",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "raindrops",
|
"slug": "raindrops",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "pangram",
|
"slug": "pangram",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "accumulate",
|
"slug": "accumulate",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "triangle",
|
"slug": "triangle",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "scrabble-score",
|
"slug": "scrabble-score",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "anagram",
|
"slug": "anagram",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "space-age",
|
"slug": "space-age",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "strain",
|
"slug": "strain",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "difference-of-squares",
|
"slug": "difference-of-squares",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "word-count",
|
"slug": "word-count",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "sum-of-multiples",
|
"slug": "sum-of-multiples",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "hamming",
|
"slug": "hamming",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "rna-transcription",
|
"slug": "rna-transcription",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "run-length-encoding",
|
"slug": "run-length-encoding",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "sublist",
|
"slug": "sublist",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "nucleotide-count",
|
"slug": "nucleotide-count",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "series",
|
"slug": "series",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "phone-number",
|
"slug": "phone-number",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "grade-school",
|
"slug": "grade-school",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "allergies",
|
"slug": "allergies",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "robot-simulator",
|
"slug": "robot-simulator",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "list-ops",
|
"slug": "list-ops",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "atbash-cipher",
|
"slug": "atbash-cipher",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "say",
|
"slug": "say",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "largest-series-product",
|
"slug": "largest-series-product",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "roman-numerals",
|
"slug": "roman-numerals",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"slug": "gigasecond",
|
"slug": "gigasecond",
|
||||||
"difficulty": 1,
|
"difficulty": 1,
|
||||||
"topics": []
|
"topics": []
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"deprecated": [
|
"deprecated": [],
|
||||||
|
"ignored": [
|
||||||
],
|
"bin",
|
||||||
"ignored": [
|
"elm-stuff",
|
||||||
"bin",
|
"node_modules",
|
||||||
"elm-stuff",
|
"docs",
|
||||||
"node_modules",
|
"tests",
|
||||||
"docs"
|
"libsysconfcpus",
|
||||||
],
|
"sysconfcpus"
|
||||||
"foregone": [
|
],
|
||||||
]
|
"foregone": []
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,46 +0,0 @@
|
||||||
{
|
|
||||||
"version": "3.0.0",
|
|
||||||
"summary": "Exercism problems in Elm.",
|
|
||||||
"repository": "https://github.com/exercism/xelm.git",
|
|
||||||
"license": "BSD3",
|
|
||||||
"source-directories": [
|
|
||||||
".",
|
|
||||||
"./exercises/hello-world",
|
|
||||||
"./exercises/leap",
|
|
||||||
"./exercises/pangram",
|
|
||||||
"./exercises/rna-transcription",
|
|
||||||
"./exercises/hamming",
|
|
||||||
"./exercises/word-count",
|
|
||||||
"./exercises/bob",
|
|
||||||
"./exercises/run-length-encoding",
|
|
||||||
"./exercises/difference-of-squares",
|
|
||||||
"./exercises/anagram",
|
|
||||||
"./exercises/raindrops",
|
|
||||||
"./exercises/triangle",
|
|
||||||
"./exercises/scrabble-score",
|
|
||||||
"./exercises/accumulate",
|
|
||||||
"./exercises/sublist",
|
|
||||||
"./exercises/sum-of-multiples",
|
|
||||||
"./exercises/strain",
|
|
||||||
"./exercises/space-age",
|
|
||||||
"./exercises/nucleotide-count",
|
|
||||||
"./exercises/series",
|
|
||||||
"./exercises/phone-number",
|
|
||||||
"./exercises/grade-school",
|
|
||||||
"./exercises/allergies",
|
|
||||||
"./exercises/robot-simulator",
|
|
||||||
"./exercises/list-ops",
|
|
||||||
"./exercises/atbash-cipher",
|
|
||||||
"./exercises/say",
|
|
||||||
"./exercises/largest-series-product",
|
|
||||||
"./exercises/roman-numerals",
|
|
||||||
"./exercises/gigasecond"
|
|
||||||
],
|
|
||||||
"exposed-modules": [],
|
|
||||||
"dependencies": {
|
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
|
||||||
}
|
|
|
@ -8,9 +8,7 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Accumulate exposing (accumulate)
|
import Accumulate exposing (accumulate)
|
||||||
|
@ -29,11 +27,3 @@ tests =
|
||||||
Expect.equal [ "olleh", "dlrow" ]
|
Expect.equal [ "olleh", "dlrow" ]
|
||||||
(accumulate String.reverse [ "hello", "world" ])
|
(accumulate String.reverse [ "hello", "world" ])
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/accumulate/tests/elm-package.json
Normal file
16
exercises/accumulate/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Allergies exposing (isAllergicTo, toList)
|
import Allergies exposing (isAllergicTo, toList)
|
||||||
|
@ -42,17 +40,9 @@ tests =
|
||||||
(255 |> toList |> List.sort)
|
(255 |> toList |> List.sort)
|
||||||
, test "ignore non allergen score parts" <|
|
, test "ignore non allergen score parts" <|
|
||||||
\() -> Expect.equal [ "eggs" ] (toList 257)
|
\() -> Expect.equal [ "eggs" ] (toList 257)
|
||||||
, test "ignore non allergen score parts" <|
|
, test "ignore all non allergen score parts" <|
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal (List.sort [ "eggs", "shellfish", "strawberries", "tomatoes", "chocolate", "pollen", "cats" ])
|
Expect.equal (List.sort [ "eggs", "shellfish", "strawberries", "tomatoes", "chocolate", "pollen", "cats" ])
|
||||||
(509 |> toList |> List.sort)
|
(509 |> toList |> List.sort)
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/allergies/tests/elm-package.json
Normal file
16
exercises/allergies/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Anagram exposing (detect)
|
import Anagram exposing (detect)
|
||||||
|
@ -34,7 +32,7 @@ tests =
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal [ "inlets" ]
|
Expect.equal [ "inlets" ]
|
||||||
(detect "listen" [ "enlists", "google", "inlets", "banana" ])
|
(detect "listen" [ "enlists", "google", "inlets", "banana" ])
|
||||||
, test "detects multiple anagrams" <|
|
, test "detects even more anagrams" <|
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal [ "gallery", "regally", "largely" ]
|
Expect.equal [ "gallery", "regally", "largely" ]
|
||||||
(detect "allergy" [ "gallery", "ballerina", "regally", "clergy", "largely", "leading" ])
|
(detect "allergy" [ "gallery", "ballerina", "regally", "clergy", "largely", "leading" ])
|
||||||
|
@ -66,7 +64,7 @@ tests =
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal []
|
Expect.equal []
|
||||||
(detect "go" [ "go Go GO" ])
|
(detect "go" [ "go Go GO" ])
|
||||||
, test "anagrams must use all letters exactly once" <|
|
, test "anagrams must use all letters exactly once (go)" <|
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal []
|
Expect.equal []
|
||||||
(detect "tapper" [ "patter" ])
|
(detect "tapper" [ "patter" ])
|
||||||
|
@ -86,16 +84,8 @@ tests =
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal []
|
Expect.equal []
|
||||||
(detect "BANANA" [ "Banana" ])
|
(detect "BANANA" [ "Banana" ])
|
||||||
, test "anagrams must use all letters exactly once" <|
|
, test "anagrams must use all letters exactly once (banana)" <|
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal []
|
Expect.equal []
|
||||||
(detect "patter" [ "tapper" ])
|
(detect "patter" [ "tapper" ])
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/anagram/tests/elm-package.json
Normal file
16
exercises/anagram/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import AtbashCipher exposing (encode, decode)
|
import AtbashCipher exposing (encode, decode)
|
||||||
|
@ -35,11 +33,3 @@ tests =
|
||||||
Expect.equal "anobstacleisoftenasteppingstone"
|
Expect.equal "anobstacleisoftenasteppingstone"
|
||||||
(decode "zmlyh gzxov rhlug vmzhg vkkrm thglm v")
|
(decode "zmlyh gzxov rhlug vmzhg vkkrm thglm v")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/atbash-cipher/tests/elm-package.json
Normal file
16
exercises/atbash-cipher/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import String
|
import String
|
||||||
|
@ -148,11 +146,3 @@ uppercaseGibberish length =
|
||||||
gibberishQuestion : Int -> String
|
gibberishQuestion : Int -> String
|
||||||
gibberishQuestion length =
|
gibberishQuestion length =
|
||||||
(gibberish length anyCharacter) ++ "?"
|
(gibberish length anyCharacter) ++ "?"
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/bob/tests/elm-package.json
Normal file
16
exercises/bob/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import DifferenceOfSquares exposing (squareOfSum, sumOfSquares, difference)
|
import DifferenceOfSquares exposing (squareOfSum, sumOfSquares, difference)
|
||||||
|
@ -37,11 +35,3 @@ tests =
|
||||||
\() -> Expect.equal 25164150 (difference 100)
|
\() -> Expect.equal 25164150 (difference 100)
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/difference-of-squares/tests/elm-package.json
Normal file
16
exercises/difference-of-squares/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Date
|
import Date
|
||||||
|
@ -39,11 +37,3 @@ date input =
|
||||||
|
|
||||||
Err reason ->
|
Err reason ->
|
||||||
Debug.crash reason
|
Debug.crash reason
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/gigasecond/tests/elm-package.json
Normal file
16
exercises/gigasecond/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import GradeSchool exposing (addStudent, studentsInGrade, allStudents)
|
import GradeSchool exposing (addStudent, studentsInGrade, allStudents)
|
||||||
|
@ -59,11 +57,3 @@ tests =
|
||||||
, test "get students in a non-existent grade" <|
|
, test "get students in a non-existent grade" <|
|
||||||
\() -> Expect.equal [] (studentsInGrade 1 GradeSchool.empty)
|
\() -> Expect.equal [] (studentsInGrade 1 GradeSchool.empty)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/grade-school/tests/elm-package.json
Normal file
16
exercises/grade-school/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Hamming exposing (distance)
|
import Hamming exposing (distance)
|
||||||
|
@ -39,11 +37,3 @@ tests =
|
||||||
, test "disallow second strand longer" <|
|
, test "disallow second strand longer" <|
|
||||||
\() -> Expect.equal Nothing (distance "ATA" "AGTG")
|
\() -> Expect.equal Nothing (distance "ATA" "AGTG")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/hamming/tests/elm-package.json
Normal file
16
exercises/hamming/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import HelloWorld exposing (helloWorld)
|
import HelloWorld exposing (helloWorld)
|
||||||
|
@ -20,11 +18,3 @@ tests =
|
||||||
\() ->
|
\() ->
|
||||||
Expect.equal "Hello, Bob!" (helloWorld (Just "Bob"))
|
Expect.equal "Hello, Bob!" (helloWorld (Just "Bob"))
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/hello-world/tests/elm-package.json
Normal file
16
exercises/hello-world/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
File diff suppressed because it is too large
Load diff
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import LargestSeriesProduct exposing (largestProduct)
|
import LargestSeriesProduct exposing (largestProduct)
|
||||||
|
@ -45,11 +43,3 @@ tests =
|
||||||
, test "rejects negative span" <|
|
, test "rejects negative span" <|
|
||||||
\() -> Expect.equal Nothing (largestProduct -1 "12345")
|
\() -> Expect.equal Nothing (largestProduct -1 "12345")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/largest-series-product/tests/elm-package.json
Normal file
16
exercises/largest-series-product/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Leap
|
import Leap
|
||||||
|
@ -25,11 +23,3 @@ tests =
|
||||||
, test "y2k" <|
|
, test "y2k" <|
|
||||||
\() -> Expect.equal True (Leap.isLeapYear 2000)
|
\() -> Expect.equal True (Leap.isLeapYear 2000)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/leap/tests/elm-package.json
Normal file
16
exercises/leap/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import ListOps exposing (..)
|
import ListOps exposing (..)
|
||||||
|
@ -67,11 +65,3 @@ tests =
|
||||||
\() -> Expect.equal (List.range 1 10) (ListOps.concat [ List.range 1 3, [], List.range 4 7, List.range 8 10 ])
|
\() -> Expect.equal (List.range 1 10) (ListOps.concat [ List.range 1 3, [], List.range 4 7, List.range 8 10 ])
|
||||||
]
|
]
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/list-ops/tests/elm-package.json
Normal file
16
exercises/list-ops/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import NucleotideCount exposing (nucleotideCounts, version)
|
import NucleotideCount exposing (nucleotideCounts, version)
|
||||||
|
@ -25,11 +23,3 @@ tests =
|
||||||
Expect.equal { a = 20, t = 21, c = 12, g = 17 }
|
Expect.equal { a = 20, t = 21, c = 12, g = 17 }
|
||||||
(nucleotideCounts "AGCTTTTCATTCTGACTGCAACGGGCAATATGTCTCTGTGTGGATTAAAAAAAGAGTGTCTGATAGCAGC")
|
(nucleotideCounts "AGCTTTTCATTCTGACTGCAACGGGCAATATGTCTCTGTGTGGATTAAAAAAAGAGTGTCTGATAGCAGC")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/nucleotide-count/tests/elm-package.json
Normal file
16
exercises/nucleotide-count/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Pangram exposing (isPangram)
|
import Pangram exposing (isPangram)
|
||||||
|
@ -51,11 +49,3 @@ tests =
|
||||||
Expect.equal True
|
Expect.equal True
|
||||||
(isPangram "Victor jagt zwölf Boxkämpfer quer über den großen Sylter Deich.")
|
(isPangram "Victor jagt zwölf Boxkämpfer quer über den großen Sylter Deich.")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/pangram/tests/elm-package.json
Normal file
16
exercises/pangram/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import PhoneNumber exposing (getNumber, prettyPrint)
|
import PhoneNumber exposing (getNumber, prettyPrint)
|
||||||
|
@ -35,11 +33,3 @@ tests =
|
||||||
, test "pretty print with full us phone number" <|
|
, test "pretty print with full us phone number" <|
|
||||||
\() -> Expect.equal (Just "(123) 456-7890") (prettyPrint "11234567890")
|
\() -> Expect.equal (Just "(123) 456-7890") (prettyPrint "11234567890")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/phone-number/tests/elm-package.json
Normal file
16
exercises/phone-number/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Raindrops exposing (raindrops)
|
import Raindrops exposing (raindrops)
|
||||||
|
@ -41,11 +39,3 @@ tests =
|
||||||
, test "105" <|
|
, test "105" <|
|
||||||
\() -> Expect.equal "PlingPlangPlong" (raindrops 105)
|
\() -> Expect.equal "PlingPlangPlong" (raindrops 105)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/raindrops/tests/elm-package.json
Normal file
16
exercises/raindrops/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import RNATranscription exposing (toRNA)
|
import RNATranscription exposing (toRNA)
|
||||||
|
@ -25,11 +23,3 @@ tests =
|
||||||
, test "correctly handles partially invalid input" <|
|
, test "correctly handles partially invalid input" <|
|
||||||
\() -> Expect.equal (Err 'U') (toRNA "UGAAXXXGACAUG")
|
\() -> Expect.equal (Err 'U') (toRNA "UGAAXXXGACAUG")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/rna-transcription/tests/elm-package.json
Normal file
16
exercises/rna-transcription/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import RobotSimulator exposing (defaultRobot, Robot, Bearing(North, East, West, South), turnRight, turnLeft, advance, simulate)
|
import RobotSimulator exposing (defaultRobot, Robot, Bearing(North, East, West, South), turnRight, turnLeft, advance, simulate)
|
||||||
|
@ -140,11 +138,3 @@ generate a list of Assert Equal assertions.
|
||||||
assertionList : List a -> List a -> List Expect.Expectation
|
assertionList : List a -> List a -> List Expect.Expectation
|
||||||
assertionList xs ys =
|
assertionList xs ys =
|
||||||
List.map2 Expect.equal xs ys
|
List.map2 Expect.equal xs ys
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/robot-simulator/tests/elm-package.json
Normal file
16
exercises/robot-simulator/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import RomanNumerals exposing (toRoman)
|
import RomanNumerals exposing (toRoman)
|
||||||
|
@ -83,11 +81,3 @@ tests =
|
||||||
Expect.equal ("MMM")
|
Expect.equal ("MMM")
|
||||||
(toRoman 3000)
|
(toRoman 3000)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/roman-numerals/tests/elm-package.json
Normal file
16
exercises/roman-numerals/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import RunLengthEncoding exposing (version, decode, encode)
|
import RunLengthEncoding exposing (version, decode, encode)
|
||||||
|
@ -37,11 +35,3 @@ tests =
|
||||||
, test "decode unicode" <|
|
, test "decode unicode" <|
|
||||||
\() -> Expect.equal "⏰⚽⚽⚽⭐⭐⏰" (decode "⏰3⚽2⭐⏰")
|
\() -> Expect.equal "⏰⚽⚽⚽⭐⭐⏰" (decode "⏰3⚽2⭐⏰")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/run-length-encoding/tests/elm-package.json
Normal file
16
exercises/run-length-encoding/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import Say exposing (say, SayError(Negative, TooLarge))
|
import Say exposing (say, SayError(Negative, TooLarge))
|
||||||
|
@ -86,11 +84,3 @@ tests =
|
||||||
)
|
)
|
||||||
(say 987654321123)
|
(say 987654321123)
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/say/tests/elm-package.json
Normal file
16
exercises/say/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"postinstall": "elm-package install -y",
|
"postinstall": "elm-package install -y",
|
||||||
"test": "elm-test Tests.elm"
|
"test": "elm-test"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm": "^0.18.0",
|
"elm": "^0.18.0",
|
||||||
|
|
|
@ -1,7 +1,5 @@
|
||||||
port module Main exposing (..)
|
module Tests exposing (..)
|
||||||
|
|
||||||
import Test.Runner.Node exposing (run, TestProgram)
|
|
||||||
import Json.Encode exposing (Value)
|
|
||||||
import Test exposing (..)
|
import Test exposing (..)
|
||||||
import Expect
|
import Expect
|
||||||
import ScrabbleScore exposing (scoreWord)
|
import ScrabbleScore exposing (scoreWord)
|
||||||
|
@ -33,11 +31,3 @@ tests =
|
||||||
, test "empty input" <|
|
, test "empty input" <|
|
||||||
\() -> Expect.equal 0 (scoreWord "")
|
\() -> Expect.equal 0 (scoreWord "")
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
||||||
main : TestProgram
|
|
||||||
main =
|
|
||||||
run emit tests
|
|
||||||
|
|
||||||
|
|
||||||
port emit : ( String, Value ) -> Cmd msg
|
|
16
exercises/scrabble-score/tests/elm-package.json
Normal file
16
exercises/scrabble-score/tests/elm-package.json
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
{
|
||||||
|
"version": "3.0.0",
|
||||||
|
"summary": "Exercism problems in Elm.",
|
||||||
|
"repository": "https://github.com/exercism/xelm.git",
|
||||||
|
"license": "BSD3",
|
||||||
|
"source-directories": [
|
||||||
|
".",
|
||||||
|
".."
|
||||||
|
],
|
||||||
|
"exposed-modules": [],
|
||||||
|
"dependencies": {
|
||||||
|
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
||||||
|
"elm-community/elm-test": "4.0.0 <= v < 5.0.0"
|
||||||
|
},
|
||||||
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
|
}
|
|
@ -8,9 +8,8 @@
|
||||||
],
|
],
|
||||||
"exposed-modules": [],
|
"exposed-modules": [],
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"elm-lang/core": "5.0.0 <= v < 6.0.0",
|
"elm-lang/core": "5.0.0 <= v < 6.0.0"
|
||||||
"elm-community/elm-test": "3.0.0 <= v < 4.0.0",
|
|
||||||
"rtfeldman/node-test-runner": "3.0.0 <= v < 4.0.0"
|
|
||||||
},
|
},
|
||||||
"elm-version": "0.18.0 <= v < 0.19.0"
|
"elm-version": "0.18.0 <= v < 0.19.0"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue