diff options
author | Hisham Muhammad <hisham@gobolinux.org> | 2017-09-29 19:35:51 -0300 |
---|---|---|
committer | Hisham Muhammad <hisham@gobolinux.org> | 2017-09-29 19:35:51 -0300 |
commit | eddfa87fe331b97dc67f8778c6ebb58386cdf6f2 (patch) | |
tree | a78f1fb305372c7123ff4fe82c63792466754543 /test | |
parent | 03757c8042d12effb32a9a05acda04b2fccc086c (diff) | |
download | luarocks-eddfa87fe331b97dc67f8778c6ebb58386cdf6f2.tar.gz luarocks-eddfa87fe331b97dc67f8778c6ebb58386cdf6f2.tar.bz2 luarocks-eddfa87fe331b97dc67f8778c6ebb58386cdf6f2.zip |
Revise README.md for test/
Diffstat (limited to 'test')
-rw-r--r-- | test/README.md | 43 |
1 files changed, 24 insertions, 19 deletions
diff --git a/test/README.md b/test/README.md index 5deaa175..8124a800 100644 --- a/test/README.md +++ b/test/README.md | |||
@@ -1,32 +1,34 @@ | |||
1 | #LuaRocks testsuite | 1 | |
2 | ##Overview | 2 | # LuaRocks testsuite |
3 | |||
4 | ## Overview | ||
5 | |||
3 | Test suite for LuaRocks project with Busted unit testing framework(http://olivinelabs.com/busted/). | 6 | Test suite for LuaRocks project with Busted unit testing framework(http://olivinelabs.com/busted/). |
4 | 7 | ||
5 | * Contains white-box & black-box tests | 8 | * Contains white-box & black-box tests |
6 | * Easy setup for your purpose on command line or from configuration file | 9 | * Easy setup for your purpose on command line or from configuration file |
7 | 10 | ||
8 | |||
9 | ## Dependencies | 11 | ## Dependencies |
12 | |||
10 | * Lua >= 5.1 | 13 | * Lua >= 5.1 |
11 | * Busted with dependencies | 14 | * Busted with dependencies |
12 | 15 | ||
16 | ## Usage | ||
13 | 17 | ||
14 | ##Usage | 18 | Running of tests is based on basic Busted usage. *-Xhelper* flag is used |
15 | Running of tests is based on basic Busted usage. *-Xhelper* flag is mandatory for inserting arguments into testing (primary black-box). Flag *--tags=* or *-t* is mandatory for specifying which tests will run. Start tests inside LuaRocks folder or specify with *-C* flag. | 19 | for inserting arguments into testing. Flag *--tags=* or *-t* is used |
20 | for specifying which tests will run. Start tests inside | ||
21 | LuaRocks folder or specify with *-C* flag. | ||
16 | 22 | ||
17 | **Arguments for Busted helper script** | 23 | **Arguments for Busted helper script** |
18 | 24 | ||
19 | ``` | 25 | ``` |
20 | lua=<version>, !mandatory! type your full version of Lua (e.g. lua=5.2.4) | 26 | env=<type>, (default:"minimal") type what kind of environment to use ["minimal", "full"] |
21 | OR | 27 | noreset, Don't reset environment after each test |
22 | luajit=<version>, !mandatory! type your full version of LuaJIT (e.g. luajit=5.2.4) | 28 | clean, remove existing testing environment |
23 | 29 | appveyor, add just if running on TravisCI | |
24 | env=<type>, (default:"minimal") type what kind of environment to use ["minimal", "full"] | 30 | travis, add just if running on TravisCI |
25 | noreset, Don't reset environment after each test | 31 | os=<version>, type your OS ["linux", "os x", "windows"] |
26 | clean, remove existing testing environment | ||
27 | appveyor, add just if running on TravisCI | ||
28 | travis, add just if running on TravisCI | ||
29 | os=<version>, type your OS ["linux", "os x", "windows"] | ||
30 | ``` | 32 | ``` |
31 | --------------------------------------------------------------------------------------------- | 33 | --------------------------------------------------------------------------------------------- |
32 | ####_**Tags** of tests are required and are in this format:_ | 34 | ####_**Tags** of tests are required and are in this format:_ |
@@ -47,8 +49,10 @@ os=<version>, type your OS ["linux", "os x", "windows"] | |||
47 | 49 | ||
48 | for example: `b_install` or `w_help` | 50 | for example: `b_install` or `w_help` |
49 | 51 | ||
50 | ###Examples | 52 | ## Examples |
53 | |||
51 | To run all tests: | 54 | To run all tests: |
55 | |||
52 | `busted` | 56 | `busted` |
53 | 57 | ||
54 | To run white-box tests in LuaRocks directory type : | 58 | To run white-box tests in LuaRocks directory type : |
@@ -57,12 +61,13 @@ To run white-box tests in LuaRocks directory type : | |||
57 | 61 | ||
58 | To run black-box tests just of *install* command (we defined our OS, so OS check is skipped.): | 62 | To run black-box tests just of *install* command (we defined our OS, so OS check is skipped.): |
59 | 63 | ||
60 | `busted -Xhelper lua=5.2.4,os=linux -t "b_install"` | 64 | `busted -Xhelper os=linux -t "b_install"` |
61 | 65 | ||
62 | To run black-box tests of *install* command, whitebox of *help* command (using *full* type of environment): | 66 | To run black-box tests of *install* command, whitebox of *help* command (using *full* type of environment): |
63 | 67 | ||
64 | `busted -Xhelper lua=5.2.4,env=full -t "b_install", "w_help"` | 68 | `busted -Xhelper env=full -t "b_install", "w_help"` |
65 | 69 | ||
66 | To run black-box tests without tests, which use ssh: | 70 | To run black-box tests without tests, which use ssh: |
67 | 71 | ||
68 | `busted -Xhelper lua=5.2.4 -t "blackbox" --exclude-tags=ssh` \ No newline at end of file | 72 | `busted -t "blackbox" --exclude-tags=ssh` |
73 | |||