spielwiese
Last change
on this file since 6fb723 was
894057,
checked in by Oleksandr Motsak <motsak@…>, 13 years ago
|
ADD: Tests from online manual (res+stat on mamawutz): short ones Tst/Manual/s.lst
|
-
Property mode set to
100644
|
File size:
559 bytes
|
Line | |
---|
1 | LIB "tst.lib"; tst_init(); |
---|
2 | pyobject two = 2; |
---|
3 | pyobject three = 3; |
---|
4 | |
---|
5 | two + three; |
---|
6 | two - three; |
---|
7 | two * three; |
---|
8 | two / three; |
---|
9 | two ^ three; |
---|
10 | two ** three; |
---|
11 | |
---|
12 | three < two; |
---|
13 | two < three; |
---|
14 | three <= two; |
---|
15 | two <= three; |
---|
16 | two == three; |
---|
17 | two == two; |
---|
18 | three > two; |
---|
19 | two > three; |
---|
20 | three >= two; |
---|
21 | two >= three; |
---|
22 | two != two; |
---|
23 | two != three; |
---|
24 | |
---|
25 | pyobject pystr = "Hello"; |
---|
26 | pystr + " World!"; |
---|
27 | pystr * 3; |
---|
28 | pystr[1]; |
---|
29 | |
---|
30 | python_run("def newfunc(*args): return list(args)"); |
---|
31 | newfunc(); |
---|
32 | newfunc(two, three); |
---|
33 | |
---|
34 | newfunc."__class__"; |
---|
35 | newfunc::"__class__"; |
---|
36 | newfunc.func_name; |
---|
37 | newfunc::func_name; |
---|
38 | |
---|
39 | tst_status(1);$ |
---|
Note: See
TracBrowser
for help on using the repository browser.