Skip to content

Commit f6c758c

Browse files
hecrjPunie
authored andcommitted
Replace test references to old elm-package.json with elm.json (#1)
1 parent 7ff6cc1 commit f6c758c

File tree

10 files changed

+76
-51
lines changed

10 files changed

+76
-51
lines changed

test/dependencies.js

+5-5
Original file line numberDiff line numberDiff line change
@@ -65,22 +65,22 @@ describe("#findAllDependencies", function() {
6565
});
6666
});
6767

68-
it("ignores an elm-package.json file that does not list the module's source directory", function() {
68+
it("ignores an elm.json file that does not list the module's source directory", function() {
6969
return findAllDependencies(prependFixturesDir("other-src/OtherParent.elm")).then(function(results) {
7070
expect(results).to.deep.equal(
7171
[ "Test/ChildA.elm" ].map(prependFixturesDir)
7272
);
7373
});
7474
});
7575

76-
it("ignores an elm-package.json file missing the source-directories key", function() {
77-
return findAllDependencies(prependFixturesDir("no-source-directories-elm-package-json/Main.elm")).then(function(results) {
76+
it("ignores an elm.json file missing the source-directories key", function() {
77+
return findAllDependencies(prependFixturesDir("no-source-directories-elm-json/Main.elm")).then(function(results) {
7878
expect(results).to.deep.equal([]);
7979
});
8080
});
8181

82-
it("gracefully ignores malformed elm-package.json files", function() {
83-
return findAllDependencies(prependFixturesDir("malformed-elm-package-json/Main.elm")).then(function(results) {
82+
it("gracefully ignores malformed elm.json files", function() {
83+
return findAllDependencies(prependFixturesDir("malformed-elm-json/Main.elm")).then(function(results) {
8484
expect(results).to.deep.equal([]);
8585
})
8686
});

test/fixtures/elm-package.json

-17
This file was deleted.

test/fixtures/elm.json

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
{
2+
"type": "application",
3+
"source-directories": [
4+
".",
5+
"other-src"
6+
],
7+
"elm-version": "0.19.0",
8+
"dependencies": {
9+
"direct": {
10+
"elm/browser": "1.0.0",
11+
"elm/core": "1.0.0",
12+
"elm/html": "1.0.0",
13+
"elm/json": "1.0.0"
14+
},
15+
"indirect": {
16+
"elm/time": "1.0.0",
17+
"elm/url": "1.0.0",
18+
"elm/virtual-dom": "1.0.0"
19+
}
20+
},
21+
"test-dependencies": {
22+
"direct": {},
23+
"indirect": {}
24+
}
25+
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"type": "application",
3+
"source-directories": [],
4+
"elm-version": "0.19.0",
5+
"dependencies": {
6+
"direct": {
7+
"elm/browser": "1.0.0",
8+
"elm/core": "1.0.0",
9+
"elm/html": "1.0.0",
10+
"elm/json": "1.0.0"
11+
},
12+
"indirect": {
13+
"elm/time": "1.0.0",
14+
"elm/url": "1.0.0",
15+
"elm/virtual-dom": "1.0.0"
16+
}
17+
},
18+
"test-dependencies": {
19+
"direct": {},
20+
"indirect": {}
21+
}
22+
}

test/fixtures/no-source-directories-elm-package-json/elm-package.json

-13
This file was deleted.

test/fixtures/other-src/elm-package.json

-16
This file was deleted.

test/fixtures/other-src/elm.json

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"type": "application",
3+
"source-directories": [
4+
"bad-directory-does-not-exist"
5+
],
6+
"elm-version": "0.19.0",
7+
"dependencies": {
8+
"direct": {
9+
"elm/browser": "1.0.0",
10+
"elm/core": "1.0.0",
11+
"elm/html": "1.0.0",
12+
"elm/json": "1.0.0"
13+
},
14+
"indirect": {
15+
"elm/time": "1.0.0",
16+
"elm/url": "1.0.0",
17+
"elm/virtual-dom": "1.0.0"
18+
}
19+
},
20+
"test-dependencies": {
21+
"direct": {},
22+
"indirect": {}
23+
}
24+
}

0 commit comments

Comments
 (0)