diff options
author | George Roman <george.roman.99@gmail.com> | 2018-05-21 19:48:54 +0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2018-05-31 13:58:50 -0300 |
commit | bd26704e6625f76e7cfc04f87543bf669542ec8d (patch) | |
tree | 737cdefffbd73bfa137c785e0a7560f742622ebf /spec/fixtures | |
parent | a18e84a704b61c361627c8c25c57beadf0cd85fd (diff) | |
download | luarocks-bd26704e6625f76e7cfc04f87543bf669542ec8d.tar.gz luarocks-bd26704e6625f76e7cfc04f87543bf669542ec8d.tar.bz2 luarocks-bd26704e6625f76e7cfc04f87543bf669542ec8d.zip |
Improve the tests for the fetch module
Diffstat (limited to 'spec/fixtures')
-rw-r--r-- | spec/fixtures/a_rock-1.0-1.src.rock | bin | 0 -> 446 bytes | |||
-rw-r--r-- | spec/fixtures/inconsistent_versions-1.0-1.rockspec | 8 | ||||
-rw-r--r-- | spec/fixtures/invalid_checksum-1.0-1.rockspec | 9 | ||||
-rw-r--r-- | spec/fixtures/invalid_rockspec_name.rockspec | 8 | ||||
-rw-r--r-- | spec/fixtures/invalid_rockspec_version-1.0-1.rockspec | 9 | ||||
-rw-r--r-- | spec/fixtures/invalid_url-1.0-1.rockspec | 8 | ||||
-rw-r--r-- | spec/fixtures/missing_mandatory_field-1.0-1.rockspec | 5 | ||||
-rw-r--r-- | spec/fixtures/unknown_field-1.0-1.rockspec | 6 |
8 files changed, 53 insertions, 0 deletions
diff --git a/spec/fixtures/a_rock-1.0-1.src.rock b/spec/fixtures/a_rock-1.0-1.src.rock new file mode 100644 index 00000000..9d0bb455 --- /dev/null +++ b/spec/fixtures/a_rock-1.0-1.src.rock | |||
Binary files differ | |||
diff --git a/spec/fixtures/inconsistent_versions-1.0-1.rockspec b/spec/fixtures/inconsistent_versions-1.0-1.rockspec new file mode 100644 index 00000000..c8c1eee2 --- /dev/null +++ b/spec/fixtures/inconsistent_versions-1.0-1.rockspec | |||
@@ -0,0 +1,8 @@ | |||
1 | package="inconsistent_versions" | ||
2 | version="1.0-2" | ||
3 | source = { | ||
4 | url = "http://example.com/foo.tar.gz" | ||
5 | } | ||
6 | build = { | ||
7 | |||
8 | } | ||
diff --git a/spec/fixtures/invalid_checksum-1.0-1.rockspec b/spec/fixtures/invalid_checksum-1.0-1.rockspec new file mode 100644 index 00000000..256cb1fe --- /dev/null +++ b/spec/fixtures/invalid_checksum-1.0-1.rockspec | |||
@@ -0,0 +1,9 @@ | |||
1 | package="invalid_checksum" | ||
2 | version="1.0-1" | ||
3 | source = { | ||
4 | url = "http://localhost:8080/file/a_rock.lua", | ||
5 | md5 = "invalid" | ||
6 | } | ||
7 | build = { | ||
8 | |||
9 | } | ||
diff --git a/spec/fixtures/invalid_rockspec_name.rockspec b/spec/fixtures/invalid_rockspec_name.rockspec new file mode 100644 index 00000000..ab70c75d --- /dev/null +++ b/spec/fixtures/invalid_rockspec_name.rockspec | |||
@@ -0,0 +1,8 @@ | |||
1 | package="invalid_rockspec_name" | ||
2 | version="1.0-1" | ||
3 | source = { | ||
4 | url = "http://example.com/foo.tar.gz" | ||
5 | } | ||
6 | build = { | ||
7 | |||
8 | } | ||
diff --git a/spec/fixtures/invalid_rockspec_version-1.0-1.rockspec b/spec/fixtures/invalid_rockspec_version-1.0-1.rockspec new file mode 100644 index 00000000..f644b3d9 --- /dev/null +++ b/spec/fixtures/invalid_rockspec_version-1.0-1.rockspec | |||
@@ -0,0 +1,9 @@ | |||
1 | rockspec_format="3.1" | ||
2 | package="invalid_rockspec_version" | ||
3 | version="1.0-1" | ||
4 | source = { | ||
5 | url = "http://example.com/foo.tar.gz" | ||
6 | } | ||
7 | build = { | ||
8 | |||
9 | } | ||
diff --git a/spec/fixtures/invalid_url-1.0-1.rockspec b/spec/fixtures/invalid_url-1.0-1.rockspec new file mode 100644 index 00000000..a74b0281 --- /dev/null +++ b/spec/fixtures/invalid_url-1.0-1.rockspec | |||
@@ -0,0 +1,8 @@ | |||
1 | package="invalid_url" | ||
2 | version="1.0-1" | ||
3 | source = { | ||
4 | url = "http://localhost:8080/file/nonexistent" | ||
5 | } | ||
6 | build = { | ||
7 | |||
8 | } | ||
diff --git a/spec/fixtures/missing_mandatory_field-1.0-1.rockspec b/spec/fixtures/missing_mandatory_field-1.0-1.rockspec new file mode 100644 index 00000000..56dac987 --- /dev/null +++ b/spec/fixtures/missing_mandatory_field-1.0-1.rockspec | |||
@@ -0,0 +1,5 @@ | |||
1 | package="missing_mandatory_field" | ||
2 | version="1.0-1" | ||
3 | source = { | ||
4 | url = "http://example.com/foo.tar.gz" | ||
5 | } | ||
diff --git a/spec/fixtures/unknown_field-1.0-1.rockspec b/spec/fixtures/unknown_field-1.0-1.rockspec new file mode 100644 index 00000000..bcad2d53 --- /dev/null +++ b/spec/fixtures/unknown_field-1.0-1.rockspec | |||
@@ -0,0 +1,6 @@ | |||
1 | package="unknown_field" | ||
2 | version="1.0-1" | ||
3 | source = { | ||
4 | url = "http://example.com/foo.tar.gz" | ||
5 | } | ||
6 | unknown="foo" | ||