diff options
| author | Hisham Muhammad <hisham@gobolinux.org> | 2016-07-14 14:43:42 -0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-07-14 14:43:42 -0300 |
| commit | 36388709d628a76c450eed20b67f008faefc36cb (patch) | |
| tree | e9e8a6959ecafcd8355b8b9614f65a613fe6ddb4 /spec/new_version_spec.lua | |
| parent | 0f63a95e991435c769584abd01b16bd748a1434b (diff) | |
| parent | 48b98f0c099dc621e1f93cccf9a9e03ff75649b6 (diff) | |
| download | luarocks-36388709d628a76c450eed20b67f008faefc36cb.tar.gz luarocks-36388709d628a76c450eed20b67f008faefc36cb.tar.bz2 luarocks-36388709d628a76c450eed20b67f008faefc36cb.zip | |
Merge pull request #588 from robooo/new-tests
New tests
Diffstat (limited to 'spec/new_version_spec.lua')
| -rw-r--r-- | spec/new_version_spec.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/new_version_spec.lua b/spec/new_version_spec.lua index 4e4d5d27..c4185b1d 100644 --- a/spec/new_version_spec.lua +++ b/spec/new_version_spec.lua | |||
| @@ -30,11 +30,19 @@ describe("LuaRocks new_version tests #blackbox #b_new_version", function() | |||
| 30 | it("LuaRocks new version invalid url", function() | 30 | it("LuaRocks new version invalid url", function() |
| 31 | assert.is_true(run.luarocks_bool("download --rockspec abelhas 1.0")) | 31 | assert.is_true(run.luarocks_bool("download --rockspec abelhas 1.0")) |
| 32 | assert.is_true(run.luarocks_bool("new_version abelhas-1.0-1.rockspec 1.1 http://luainvalid")) | 32 | assert.is_true(run.luarocks_bool("new_version abelhas-1.0-1.rockspec 1.1 http://luainvalid")) |
| 33 | assert.is.truthy(lfs.attributes("abelhas-1.1-1.rockspec")) | ||
| 33 | test_env.remove_files(lfs.currentdir(), "abelhas--") | 34 | test_env.remove_files(lfs.currentdir(), "abelhas--") |
| 34 | end) | 35 | end) |
| 35 | end) | 36 | end) |
| 36 | 37 | ||
| 37 | describe("LuaRocks new_version more complex tests", function() | 38 | describe("LuaRocks new_version more complex tests", function() |
| 39 | it("LuaRocks new version with remote spec", function() | ||
| 40 | assert.is_true(run.luarocks_bool("new_version https://luarocks.org/manifests/luarocks/luasocket-2.0.2-6.rockspec")) | ||
| 41 | assert.is.truthy(lfs.attributes("luasocket-2.0.2-6.rockspec")) | ||
| 42 | assert.is.truthy(lfs.attributes("luasocket-2.0.2-7.rockspec")) | ||
| 43 | test_env.remove_files(lfs.currentdir(), "luasocket--") | ||
| 44 | end) | ||
| 45 | |||
| 38 | it("LuaRocks new_version of luacov", function() | 46 | it("LuaRocks new_version of luacov", function() |
| 39 | assert.is_true(run.luarocks_bool("download --rockspec luacov 0.11.0")) | 47 | assert.is_true(run.luarocks_bool("download --rockspec luacov 0.11.0")) |
| 40 | assert.is_true(run.luarocks_bool("new_version luacov-0.11.0-1.rockspec 0.2")) | 48 | assert.is_true(run.luarocks_bool("new_version luacov-0.11.0-1.rockspec 0.2")) |
