1 | #!bin/ysh
|
2 | #
|
3 | # System tests for ul-table.
|
4 | #
|
5 | # Usage:
|
6 | # doctools/ul-table-test.ysh <function name>
|
7 |
|
8 | # TODO:
|
9 | # - run tests with python2 and python3
|
10 | # - run with CommonMark and Markdown.pl
|
11 | # - CommonMark only works under Python 2 now? But we could add Python 3.
|
12 |
|
13 | source $LIB_OSH/task-five.sh
|
14 | #source $LIB_YSH/yblocks.ysh
|
15 |
|
16 | # proc doesn't work with task-five!
|
17 | # we need task-five.ysh?
|
18 | proc unit-py2 {
|
19 | # like test/unit.sh
|
20 | PYTHONPATH='.:vendor/' doctools/ul_table_test.py
|
21 | }
|
22 |
|
23 | unit-py2() {
|
24 | # like test/unit.sh
|
25 | PYTHONPATH='.:vendor/' doctools/ul_table_test.py
|
26 | }
|
27 |
|
28 | # Problem: We import cmark, which imports ctypes
|
29 | unit-py3() {
|
30 | # like test/unit.sh
|
31 | PYTHONPATH='.:vendor/' python3 doctools/ul_table_test.py
|
32 | }
|
33 |
|
34 | proc run-tests() {
|
35 | devtools/byo.sh test $0
|
36 | }
|
37 |
|
38 | task-five "$@"
|