Ticket #33894: check.i

File check.i, 2.2 KB (added by paumard, 12 years ago)

run from the unpacked source as "yorick -batch check.i"

Line 
1/*
2   Upper level check.i file for the Yeti plugin.
3
4   Make sure the companion yeti_*_test.i files are in your Yorick path.
5
6   run "yorick -i check.i", you should get a self-explanatory output.
7*/
8
9// Set paths to find local yeti version
10if (dir=find_in_path("yeti.i", path="./:yeti/:../yeti/", takefirst=1)) {
11  dir=dirname(dir);
12  plug_dir,_(dir, plug_dir());
13  set_path,dir+":"+get_path();
14 }
15
16write,"-> Trying to load Yeti plugin...";
17#include "yeti.i"
18
19write,"-> Checking availability of basic Yeti functions...";
20#include "yeti_test.i"
21write,"-> Basic Yeti functions present";
22
23write,"-> Checking Yeti hash tables functions...";
24#include "yeti_hash_test.i"
25write,"-> Yeti hash tables functions OK";
26
27write,"-> Checking Yeti hierarchical data format (YHD) functions...";
28#include "yeti_yhdf.i"
29#include "yeti_yhdf_test.i"
30yhd_test,"yeti_yhdf_test.tmp";
31write,"-> YHD functions: no error, you may want to check detailed output";
32
33write,"-> Checking Yeti sparse matrix operation functions...";
34#include "yeti_sparse_test.i"
35write,"-> Sparse matrix operations: no error, you may want to check detailed output";
36
37write,"-> Looking for Yeti-FFTW test suite...";
38if (dir=find_in_path("yeti_fftw_test.i", path="./:yeti_fftw/:../yeti_fftw/:"+get_path(), takefirst=1)) {
39  dir=dirname(dir);
40  plug_dir,_(dir, plug_dir());
41  set_path,dir+":"+get_path();
42  include, "yeti_fftw.i", 1;
43  include, "yeti_fftw_test.i", 1;
44  write,"-> Yeti-FFTW loaded successfully, running now...";
45  fftw_time,[2,256,256], repeat=10;
46  fftw_compare,[2,256,256];
47  write,"-> Yeti-FFTW tests successful.";
48 } else write, "-> Yeti-FFTW test suite not found.";
49
50
51write,"____________________________________________________________________________";
52write,"";
53write,"All tests passed without triggering errors.";
54write,"";
55write,"You may want to check detailed output:";
56write,"Ouput values in sparse matrix operations should be 0 or very small,";
57write,"A few \"*** value(s) differ for member ...\" messages are OK when checking";
58write,"YHD functions with various foreign encodings (they indicate over/underflows";
59write,"in encodings with types shorter than native).";
60write,"____________________________________________________________________________";
61write,"";
62quit;