File: ignore_parameter_runme.php4

package info (click to toggle)
swig1.3 1.3.24-1
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 19,336 kB
  • ctags: 10,604
  • sloc: cpp: 27,917; ansic: 24,160; yacc: 4,412; python: 4,255; java: 4,156; makefile: 3,735; sh: 3,552; cs: 2,250; ruby: 2,150; lisp: 1,605; tcl: 1,136; perl: 980; php: 879; ml: 825
file content (39 lines) | stat: -rw-r--r-- 1,152 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<?php
// Sample test file

require "tests.php4";
require "ignore_parameter.php";

// No new functions
check::functions(array(jaguar,lotus,tvr,ferrari));
// No new classes
check::classes(array(sportscars,minicooper,morrisminor,fordanglia,austinallegro));
// now new vars
check::globals(array());

check::equal(jaguar(2,3.4),"hello",'jaguar(2,3.4)=="hello"');
check::equal(lotus("eek",3.4),101,'lotus("eek",3.4)==101');
check::equal(tvr("eek",2),8.8,'tvr("eek",2)==8.8');
check::equal(ferrari(),101,'ferrari(2)==101');

$sc=new sportscars();
check::classname("sportscars",$sc);
check::equal($sc->daimler(2,3.4),"hello",'$sc->daimler(2,3.4)=="hello"');
check::equal($sc->astonmartin("eek",3.4),101,'$sc->mastonmartin("eek",3.4)==101');
check::equal($sc->bugatti("eek",2),8.8,'$sc->bugatti("eek",2)==8.8');
check::equal($sc->lamborghini(),101,'$sc->lamborghini(2)==101');

$mc=new minicooper(2,3.4);
check::classname("minicooper",$mc);

$mm=new morrisminor("eek",3.4);
check::classname("morrisminor",$mm);

$fa=new fordanglia("eek",2);
check::classname("fordanglia",$fa);

$aa=new austinallegro();
check::classname("austinallegro",$aa);

check::done();
?>