2
2
3
3
namespace phpmock \integration ;
4
4
5
+ use PHPUnit \Framework \TestCase ;
6
+
5
7
/**
6
8
* Tests MockDelegateFunctionBuilder.
7
9
*
10
12
* @license http://www.wtfpl.net/txt/copying/ WTFPL
11
13
* @see MockDelegateFunctionBuilder
12
14
*/
13
- class MockDelegateFunctionBuilderTest extends \PHPUnit_Framework_TestCase
15
+ class MockDelegateFunctionBuilderTest extends TestCase
14
16
{
15
17
16
18
/**
@@ -34,14 +36,14 @@ public function testDiverseSignaturesProduceDifferentClasses()
34
36
{
35
37
$ builder = new MockDelegateFunctionBuilder ();
36
38
37
- $ builder ->build (create_function ( '' , '' ) );
39
+ $ builder ->build (' f0 ' );
38
40
$ class1 = $ builder ->getFullyQualifiedClassName ();
39
41
40
- $ builder ->build (create_function ( ' $a ' , '' ) );
42
+ $ builder ->build (' f1 ' );
41
43
$ class2 = $ builder ->getFullyQualifiedClassName ();
42
44
43
45
$ builder2 = new MockDelegateFunctionBuilder ();
44
- $ builder2 ->build (create_function ( ' $a, $b ' , '' ) );
46
+ $ builder2 ->build (' f2 ' );
45
47
$ class3 = $ builder2 ->getFullyQualifiedClassName ();
46
48
47
49
$ this ->assertNotEquals ($ class1 , $ class2 );
@@ -56,13 +58,12 @@ public function testDiverseSignaturesProduceDifferentClasses()
56
58
*/
57
59
public function testSameSignaturesProduceSameClass ()
58
60
{
59
- $ signature = '$a ' ;
60
61
$ builder = new MockDelegateFunctionBuilder ();
61
62
62
- $ builder ->build (create_function ( $ signature , '' ) );
63
+ $ builder ->build (' f1 ' );
63
64
$ class1 = $ builder ->getFullyQualifiedClassName ();
64
65
65
- $ builder ->build (create_function ( $ signature , '' ) );
66
+ $ builder ->build (' f1 ' );
66
67
$ class2 = $ builder ->getFullyQualifiedClassName ();
67
68
68
69
$ this ->assertEquals ($ class1 , $ class2 );
@@ -74,6 +75,8 @@ public function testSameSignaturesProduceSameClass()
74
75
* @test
75
76
* @backupStaticAttributes enabled
76
77
* @dataProvider provideTestBackupStaticAttributes
78
+ *
79
+ * @doesNotPerformAssertions
77
80
*/
78
81
public function testBackupStaticAttributes ()
79
82
{
@@ -100,6 +103,8 @@ public function provideTestBackupStaticAttributes()
100
103
* @test
101
104
* @runInSeparateProcess
102
105
* @dataProvider provideTestDeserializationInNewProcess
106
+ *
107
+ * @doesNotPerformAssertions
103
108
*/
104
109
public function testDeserializationInNewProcess ($ data )
105
110
{
0 commit comments