source: git/Tst/README @ b35b93

spielwiese
Last change on this file since b35b93 was b35b93, checked in by Olaf Bachmann <obachman@…>, 25 years ago
This commit was generated by cvs2svn to compensate for changes in r1396, which included commits to RCS files with non-trunk default branches. git-svn-id: file:///usr/local/Singular/svn/trunk@1397 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 3.1 KB
Line 
1README file for Singular test-suite
2===================================
3
4This is the test-suite for Singular. This directory contains
5
6regress.cmd     -- perl script which drives tests
7Short           -- directory containing "short" tests
8Long            -- directory containing "long" tests
9Old             -- directory containing "old" (TST) tests
10
11To run Singular test(s):
12------------------------
131.) Put the Singular binary in this directory
142.) cd to one of the directories above
153.) run
16     ../regress.cmd [*.tst] [*.lst]
17    with the desired tst (i.e., Singular test scripts) or lst (list
18    of tst files) file(s).
194.) For each file xx.tst,
20      ../Singular -tqr12345678 xx.tst > xx.new.tst
21      diff xx.res xx.new.res | tee xx.diff
22    is run.
235.) If no diffs were found, xx.diff and xx.new.res are rm'ed and
24    xx.res is gzip'ed. Otherwise (i.e., diffs were found), xx.diff and
25    xx.new.res are kept, diffs are printed to stdout, and regress.cmd
26    exits with exit status != 0.
27
28Do also
29   ../regress.cmd -h
30for some more details on regress.cmd.
31
32To add a new test for a library/commando to the test-suite:
33-----------------------------------------------------------
34* The following files need to be provided:
35        short/xx_s.tst : Singular code for short and basic tests
36        long/xx_l.tst : Singular code for long and extended tests
37        short/xx_s.res : Result output of xx_s.tst
38        long/xx_l.res : Result output of xx_l.tst
39  or, alternatively:
40        short/xx.tst: Singular code for short tests, only
41        short/xx.res : Result output of xx.tst
42
43* xx_s.tst should test the essential functionality of the
44  library/commando in a relatively short time (say, in no more than
45  30s).
46
47* xx_l.tst should test the functionality of the
48  library/commando in detail so that, if possible, all relevant
49  cases/results are tested. Nevertheless, such a test should not run
50  longer than, say, 10 minutes.
51
52* If useful test do generally execute in a short time, have xx.tst,
53  only.
54
55* Rules for providing tst files:
56  1.) tst files always start with the following three commandos as
57  preamble:
58         LIB "tst.lib";
59         tst_init();
60         tst_ignore("CVS ID $Id:$");
61  tst_init() writes some general info to stdout (like date,
62  uname, hostname, version, etc.). The library tst.lib (appended
63  below) provides, among others, the routines tst_init() and
64  tst_ignore().
65
66  2.) All system-dependent output (like run-times, memory usages,
67  pathnames, dates, etc.) must be output by means of the routine
68  tst_ignore(...):
69  tst_ignore(val [, keyword]): 'val' can have arbitrary type for which
70                               a string conversion exists;
71                               if present, keyword must be one of the
72                               following strings: "time", "memory"
73  tst_ignore() outputs 'val' by prepending the following prefix:
74  no keyword --       // ignore:
75  "time" keyword --   // ignore: time:
76  "memory" keyword -- // ignore: memory:
77  which causes automatic tests to ignore these lines when doing a diff
78  on result files. If possible, short tests should not contain
79  system-dependent output.
80
81* Command for generating *.res files:
82  cd <directopry where xx.tst should reside>; ../regress.cmd -g xx.tst
83
84
Note: See TracBrowser for help on using the repository browser.