-
Notifications
You must be signed in to change notification settings - Fork 36
Expand file tree
/
Copy pathExtendingClassTest.php
More file actions
42 lines (38 loc) · 1014 Bytes
/
ExtendingClassTest.php
File metadata and controls
42 lines (38 loc) · 1014 Bytes
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
40
41
42
<?php
declare(strict_types=1);
namespace PHPJava\Tests\Cases;
use PHPJava\IO\Standard\Output;
class ExtendingClassTest extends Base
{
protected $fixtures = [
'SuperExtendingClassTest',
'ExtendingClassTest1',
'ExtendingClassTest2',
];
public function testExtendingClassPattern1()
{
static::$initiatedJavaClasses['ExtendingClassTest1']
->getInvoker()
->getStatic()
->getMethods()
->call(
'main',
[]
);
$result = Output::getHeapspace();
$this->assertEquals("99999\n", $result);
}
public function testExtendingClassPattern2()
{
static::$initiatedJavaClasses['ExtendingClassTest2']
->getInvoker()
->getStatic()
->getMethods()
->call(
'main',
[]
);
$result = Output::getHeapspace();
$this->assertEquals("12345\n", $result);
}
}