File: 033.phpt

package info (click to toggle)
php-uopz 7.1.1%2B%2B-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 688 kB
  • sloc: ansic: 2,137; xml: 335; makefile: 2
file content (27 lines) | stat: -rw-r--r-- 360 bytes parent folder | download | duplicates (2)
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
--TEST--
new IS_UNUSED op1 with mock
--EXTENSIONS--
uopz
--INI--
uopz.disable=0
--FILE--
<?php
class Test {
	public static function run() {
		uopz_set_mock(self::class, Mock::class);

		$mock = new self();

		var_dump($mock->method());
	}
}

class Mock extends Test {
	public static function method() {
		return true;
	}
}

Test::run();
--EXPECTF--
bool(true)