From 0c2be40afc2abceaeca2631c3cce78639307dd31 Mon Sep 17 00:00:00 2001 From: Jonathan Turner Date: Mon, 3 Jun 2019 13:26:29 +1200 Subject: [PATCH] Fix integration tests for Linux --- src/tests.rs | 6 +++--- tests/json_roundtrip.out | 2 +- tests/json_roundtrip.txt | 3 ++- tests/open_json.txt | 3 ++- tests/open_toml.txt | 3 ++- tests/sort_by.txt | 3 ++- tests/split.out | 3 +-- tests/split.txt | 3 ++- tests/toml_roundtrip.txt | 3 ++- 9 files changed, 17 insertions(+), 12 deletions(-) diff --git a/src/tests.rs b/src/tests.rs index 13142dde78..338cc05c2b 100644 --- a/src/tests.rs +++ b/src/tests.rs @@ -55,12 +55,12 @@ mod tests { } #[test] - fn test_toml() { + fn open_toml() { test_helper("open_toml"); } #[test] - fn test_json() { + fn open_json() { test_helper("open_json"); } @@ -83,4 +83,4 @@ mod tests { fn split() { test_helper("split"); } -} \ No newline at end of file +} diff --git a/tests/json_roundtrip.out b/tests/json_roundtrip.out index ba2d8d98da..37622491df 100644 --- a/tests/json_roundtrip.out +++ b/tests/json_roundtrip.out @@ -1 +1 @@ -"example glossary" +S diff --git a/tests/json_roundtrip.txt b/tests/json_roundtrip.txt index 285697ec0f..dc8c60286a 100644 --- a/tests/json_roundtrip.txt +++ b/tests/json_roundtrip.txt @@ -1,2 +1,3 @@ -open tests\test.json | to-json | from-json | select glossary.title | echo $it +cd tests +open test.json | to-json | from-json | select glossary.GlossDiv.title | echo $it exit diff --git a/tests/open_json.txt b/tests/open_json.txt index 9126fb3f63..6320004852 100644 --- a/tests/open_json.txt +++ b/tests/open_json.txt @@ -1,2 +1,3 @@ -open tests\test.json | select glossary.GlossDiv.GlossList.GlossEntry.GlossSee | echo $it +cd tests +open test.json | select glossary.GlossDiv.GlossList.GlossEntry.GlossSee | echo $it exit diff --git a/tests/open_toml.txt b/tests/open_toml.txt index 4c93effadf..41ebdad834 100644 --- a/tests/open_toml.txt +++ b/tests/open_toml.txt @@ -1,2 +1,3 @@ -open tests\test.toml | select package.edition | echo $it +cd tests +open test.toml | select package.edition | echo $it exit diff --git a/tests/sort_by.txt b/tests/sort_by.txt index 235c76b8e8..be00978d40 100644 --- a/tests/sort_by.txt +++ b/tests/sort_by.txt @@ -1,2 +1,3 @@ -open tests\test.toml --raw | split-row "\n" | skip 1 | first 4 | split-column "=" | sort-by Column1 | skip 1 | first 1 | select Column1 | trim | echo $it +cd tests +open test.toml --raw | split-row "\n" | skip 1 | first 4 | split-column "=" | sort-by Column1 | skip 1 | first 1 | select Column1 | trim | echo $it exit diff --git a/tests/split.out b/tests/split.out index 4c45f1172b..f121bdbff4 100644 --- a/tests/split.out +++ b/tests/split.out @@ -1,2 +1 @@ -name -version +name diff --git a/tests/split.txt b/tests/split.txt index 8b8189f4a6..67a9804576 100644 --- a/tests/split.txt +++ b/tests/split.txt @@ -1,2 +1,3 @@ -open tests\test.toml --raw | split-row "\n" | skip 1 | first 2 | split-column "=" | select Column1 | trim | echo $it +cd tests +open test.toml --raw | split-row "\n" | skip 1 | first 1 | split-column "=" | select Column1 | trim | echo $it exit diff --git a/tests/toml_roundtrip.txt b/tests/toml_roundtrip.txt index 1d150b9436..a519fbe86a 100644 --- a/tests/toml_roundtrip.txt +++ b/tests/toml_roundtrip.txt @@ -1,2 +1,3 @@ -open tests\test.toml | to-toml | from-toml | select package.name | echo $it +cd tests +open test.toml | to-toml | from-toml | select package.name | echo $it exit