Skip to content

Commit b0c14ae

Browse files
committed
Adding default test classes for phpunit + generator script - refs #5568
1 parent 38c8854 commit b0c14ae

26 files changed

+2853
-0
lines changed
12 KB
Binary file not shown.

tests/phpunit/README.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Do not modify these test classes by hand. They will probably get overwritten
2+
with the next automatic generation. Instead, use copies of the existing files
3+
and suffix them with "Custom" to maintain them in the code versioning system.
4+
For example: AccessTestCustom.class.php
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
<?php
2+
/**
3+
* Generated by PHPUnit_SkeletonGenerator on 2012-10-01 at 14:44:08.
4+
*/
5+
class AccessAllTest extends PHPUnit_Framework_TestCase
6+
{
7+
/**
8+
* @var AccessAll
9+
*/
10+
protected $object;
11+
12+
/**
13+
* Sets up the fixture, for example, opens a network connection.
14+
* This method is called before a test is executed.
15+
*/
16+
protected function setUp()
17+
{
18+
$this->object = new AccessAll;
19+
}
20+
21+
/**
22+
* Tears down the fixture, for example, closes a network connection.
23+
* This method is called after a test is executed.
24+
*/
25+
protected function tearDown()
26+
{
27+
}
28+
29+
/**
30+
* @covers AccessAll::instance
31+
* @todo Implement testInstance().
32+
*/
33+
public function testInstance()
34+
{
35+
// Remove the following lines when you implement this test.
36+
$this->markTestIncomplete(
37+
'This test has not been implemented yet.'
38+
);
39+
}
40+
41+
/**
42+
* @covers AccessAll::can_edit
43+
* @todo Implement testCan_edit().
44+
*/
45+
public function testCan_edit()
46+
{
47+
// Remove the following lines when you implement this test.
48+
$this->markTestIncomplete(
49+
'This test has not been implemented yet.'
50+
);
51+
}
52+
53+
/**
54+
* @covers AccessAll::can_view
55+
* @todo Implement testCan_view().
56+
*/
57+
public function testCan_view()
58+
{
59+
// Remove the following lines when you implement this test.
60+
$this->markTestIncomplete(
61+
'This test has not been implemented yet.'
62+
);
63+
}
64+
65+
/**
66+
* @covers AccessAll::authorize
67+
* @todo Implement testAuthorize().
68+
*/
69+
public function testAuthorize()
70+
{
71+
// Remove the following lines when you implement this test.
72+
$this->markTestIncomplete(
73+
'This test has not been implemented yet.'
74+
);
75+
}
76+
}
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
<?php
2+
/**
3+
* Generated by PHPUnit_SkeletonGenerator on 2012-10-01 at 14:44:08.
4+
*/
5+
class AccessForbiddenTest extends PHPUnit_Framework_TestCase
6+
{
7+
/**
8+
* @var AccessForbidden
9+
*/
10+
protected $object;
11+
12+
/**
13+
* Sets up the fixture, for example, opens a network connection.
14+
* This method is called before a test is executed.
15+
*/
16+
protected function setUp()
17+
{
18+
$this->object = new AccessForbidden;
19+
}
20+
21+
/**
22+
* Tears down the fixture, for example, closes a network connection.
23+
* This method is called after a test is executed.
24+
*/
25+
protected function tearDown()
26+
{
27+
}
28+
29+
/**
30+
* @covers AccessForbidden::instance
31+
* @todo Implement testInstance().
32+
*/
33+
public function testInstance()
34+
{
35+
// Remove the following lines when you implement this test.
36+
$this->markTestIncomplete(
37+
'This test has not been implemented yet.'
38+
);
39+
}
40+
41+
/**
42+
* @covers AccessForbidden::can_edit
43+
* @todo Implement testCan_edit().
44+
*/
45+
public function testCan_edit()
46+
{
47+
// Remove the following lines when you implement this test.
48+
$this->markTestIncomplete(
49+
'This test has not been implemented yet.'
50+
);
51+
}
52+
53+
/**
54+
* @covers AccessForbidden::can_view
55+
* @todo Implement testCan_view().
56+
*/
57+
public function testCan_view()
58+
{
59+
// Remove the following lines when you implement this test.
60+
$this->markTestIncomplete(
61+
'This test has not been implemented yet.'
62+
);
63+
}
64+
65+
/**
66+
* @covers AccessForbidden::authorize
67+
* @todo Implement testAuthorize().
68+
*/
69+
public function testAuthorize()
70+
{
71+
// Remove the following lines when you implement this test.
72+
$this->markTestIncomplete(
73+
'This test has not been implemented yet.'
74+
);
75+
}
76+
}
Lines changed: 100 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
<?php
2+
/**
3+
* Generated by PHPUnit_SkeletonGenerator on 2012-10-01 at 14:44:07.
4+
*/
5+
class AccessTest extends PHPUnit_Framework_TestCase
6+
{
7+
/**
8+
* @var Access
9+
*/
10+
protected $object;
11+
12+
/**
13+
* Sets up the fixture, for example, opens a network connection.
14+
* This method is called before a test is executed.
15+
*/
16+
protected function setUp()
17+
{
18+
$this->object = new Access;
19+
}
20+
21+
/**
22+
* Tears down the fixture, for example, closes a network connection.
23+
* This method is called after a test is executed.
24+
*/
25+
protected function tearDown()
26+
{
27+
}
28+
29+
/**
30+
* @covers Access::all
31+
* @todo Implement testAll().
32+
*/
33+
public function testAll()
34+
{
35+
// Remove the following lines when you implement this test.
36+
$this->markTestIncomplete(
37+
'This test has not been implemented yet.'
38+
);
39+
}
40+
41+
/**
42+
* @covers Access::forbidden
43+
* @todo Implement testForbidden().
44+
*/
45+
public function testForbidden()
46+
{
47+
// Remove the following lines when you implement this test.
48+
$this->markTestIncomplete(
49+
'This test has not been implemented yet.'
50+
);
51+
}
52+
53+
/**
54+
* @covers Access::is_token_valid
55+
* @todo Implement testIs_token_valid().
56+
*/
57+
public function testIs_token_valid()
58+
{
59+
// Remove the following lines when you implement this test.
60+
$this->markTestIncomplete(
61+
'This test has not been implemented yet.'
62+
);
63+
}
64+
65+
/**
66+
* @covers Access::get_session_token
67+
* @todo Implement testGet_session_token().
68+
*/
69+
public function testGet_session_token()
70+
{
71+
// Remove the following lines when you implement this test.
72+
$this->markTestIncomplete(
73+
'This test has not been implemented yet.'
74+
);
75+
}
76+
77+
/**
78+
* @covers Access::get_token
79+
* @todo Implement testGet_token().
80+
*/
81+
public function testGet_token()
82+
{
83+
// Remove the following lines when you implement this test.
84+
$this->markTestIncomplete(
85+
'This test has not been implemented yet.'
86+
);
87+
}
88+
89+
/**
90+
* @covers Access::authorize
91+
* @todo Implement testAuthorize().
92+
*/
93+
public function testAuthorize()
94+
{
95+
// Remove the following lines when you implement this test.
96+
$this->markTestIncomplete(
97+
'This test has not been implemented yet.'
98+
);
99+
}
100+
}
Lines changed: 136 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,136 @@
1+
<?php
2+
/**
3+
* Generated by PHPUnit_SkeletonGenerator on 2012-10-01 at 14:44:08.
4+
*/
5+
class AccessTokenTest extends PHPUnit_Framework_TestCase
6+
{
7+
/**
8+
* @var AccessToken
9+
*/
10+
protected $object;
11+
12+
/**
13+
* Sets up the fixture, for example, opens a network connection.
14+
* This method is called before a test is executed.
15+
*/
16+
protected function setUp()
17+
{
18+
$this->object = new AccessToken;
19+
}
20+
21+
/**
22+
* Tears down the fixture, for example, closes a network connection.
23+
* This method is called after a test is executed.
24+
*/
25+
protected function tearDown()
26+
{
27+
}
28+
29+
/**
30+
* @covers AccessToken::empty_token
31+
* @todo Implement testEmpty_token().
32+
*/
33+
public function testEmpty_token()
34+
{
35+
// Remove the following lines when you implement this test.
36+
$this->markTestIncomplete(
37+
'This test has not been implemented yet.'
38+
);
39+
}
40+
41+
/**
42+
* @covers AccessToken::parse
43+
* @todo Implement testParse().
44+
*/
45+
public function testParse()
46+
{
47+
// Remove the following lines when you implement this test.
48+
$this->markTestIncomplete(
49+
'This test has not been implemented yet.'
50+
);
51+
}
52+
53+
/**
54+
* @covers AccessToken::create
55+
* @todo Implement testCreate().
56+
*/
57+
public function testCreate()
58+
{
59+
// Remove the following lines when you implement this test.
60+
$this->markTestIncomplete(
61+
'This test has not been implemented yet.'
62+
);
63+
}
64+
65+
/**
66+
* @covers AccessToken::get_id
67+
* @todo Implement testGet_id().
68+
*/
69+
public function testGet_id()
70+
{
71+
// Remove the following lines when you implement this test.
72+
$this->markTestIncomplete(
73+
'This test has not been implemented yet.'
74+
);
75+
}
76+
77+
/**
78+
* @covers AccessToken::get_user_id
79+
* @todo Implement testGet_user_id().
80+
*/
81+
public function testGet_user_id()
82+
{
83+
// Remove the following lines when you implement this test.
84+
$this->markTestIncomplete(
85+
'This test has not been implemented yet.'
86+
);
87+
}
88+
89+
/**
90+
* @covers AccessToken::get_key
91+
* @todo Implement testGet_key().
92+
*/
93+
public function testGet_key()
94+
{
95+
// Remove the following lines when you implement this test.
96+
$this->markTestIncomplete(
97+
'This test has not been implemented yet.'
98+
);
99+
}
100+
101+
/**
102+
* @covers AccessToken::is_empty
103+
* @todo Implement testIs_empty().
104+
*/
105+
public function testIs_empty()
106+
{
107+
// Remove the following lines when you implement this test.
108+
$this->markTestIncomplete(
109+
'This test has not been implemented yet.'
110+
);
111+
}
112+
113+
/**
114+
* @covers AccessToken::is_valid
115+
* @todo Implement testIs_valid().
116+
*/
117+
public function testIs_valid()
118+
{
119+
// Remove the following lines when you implement this test.
120+
$this->markTestIncomplete(
121+
'This test has not been implemented yet.'
122+
);
123+
}
124+
125+
/**
126+
* @covers AccessToken::__toString
127+
* @todo Implement test__toString().
128+
*/
129+
public function test__toString()
130+
{
131+
// Remove the following lines when you implement this test.
132+
$this->markTestIncomplete(
133+
'This test has not been implemented yet.'
134+
);
135+
}
136+
}

0 commit comments

Comments
 (0)