summaryrefslogtreecommitdiff
path: root/pages
diff options
context:
space:
mode:
authorAndrew Williams <andy@andywilliams.me>2018-01-05 06:00:07 -0800
committerapache <apache@e5-web1.enlightenment.org>2018-01-05 06:00:07 -0800
commitc92a13ee8150b260a1924c9290dce1689b7a2fc0 (patch)
treedce81a6e17c6b79e917bf6f606acbc0c9205a4ef /pages
parent4e792731c73a60eaf81ee598d31f0eb5b81bece7 (diff)
Wiki page enlightenment-regression.md changed with summary [] by Andrew Williams
Diffstat (limited to 'pages')
-rw-r--r--pages/contrib/devs/enlightenment-regression.md.txt61
1 files changed, 59 insertions, 2 deletions
diff --git a/pages/contrib/devs/enlightenment-regression.md.txt b/pages/contrib/devs/enlightenment-regression.md.txt
index 1e2378282..10396ad14 100644
--- a/pages/contrib/devs/enlightenment-regression.md.txt
+++ b/pages/contrib/devs/enlightenment-regression.md.txt
@@ -15,14 +15,71 @@ but it must be installed using the following instructions before it can be used.
15 15
16The test suite should be cloned from git and installed in the usual autotools manner: 16The test suite should be cloned from git and installed in the usual autotools manner:
17 17
18```
19 $ git clone https://git.enlightenment.org/devs/discomfitor/test-e.git 18 $ git clone https://git.enlightenment.org/devs/discomfitor/test-e.git
20 $ cd test-e 19 $ cd test-e
21 $ ./autogen.sh --prefix=<your enlightenment prefix here> 20 $ ./autogen.sh --prefix=<your enlightenment prefix here>
22 $ make 21 $ make
23 $ make install 22 $ make install
24```
25 23
26## Running Tests ## 24## Running Tests ##
27 25
26Tests are invoked using the run script:
27
28 * ``./run.sh`` runs all available tests
29 * ``./run.sh <test1> <test2>`` run the specified tests
30
31Graphical output is rendered to a png file matching the name of the test i.e. test1.png.
32
33Test stdout and stderr are saved to a log file with the same name i.e. test1.log.
34
35## Configuration ##
36
37The following environment variables are supported to control the behaviour of the tests:
38
39VG_ON
40: Run test(s) under valgrind
41
42GDB_ON
43: Automatically print a backtrace on crash
44
45TEST_EXIT
46: Use exit() instead of logging out after tests
47
48CLEAN
49: Run ‘git clean -dxf’ before running tests
50
51DELAY_ON
52: Wait 4 extra seconds before beginning tests
53
54STRACE_ON
55: Run tests under strace
56
57E_COMP_ENGINE
58: ‘sw’ or ‘gl’ to set software or gl rendering
59
60E_WL_FORCE
61: ‘buffer’, ‘drm’, ‘x11’, ‘wl’ to set the output engine
62
63Additionally you can change the expected outcome of a test by editing the
64imgs/testname.png file. If you delete the file then it will be recreated
65from the output of the next test run.
66
28## Adding New Tests ## 67## Adding New Tests ##
68
69To add a new test to the suite follow these steps
70
71 Create src/<newtestname>.c
72 Copy scripts/basic.sh to scripts/<newtestname>.sh
73 Add src/<newtestname>.c to src/Makefile.mk
74 Add RUN_TEST(<newtestname>); to src/e_mod_main.c
75 Add TEST_FN(<newtestname>); to src/e_mod_main.h
76
77Add the following content to src/<newtestname>.c as a starting point:
78
79 #include "e_mod_main.h"
80 TEST_FN(<testname>)
81 {
82 // Initialize stuff here
83 }
84
85For further examples of how to write tests please check the content of existing test files. \ No newline at end of file