Skip to content

Commit 201206f

Browse files
authored
Merge pull request #283 from lloc/chore
Tests enhanced
2 parents ce90e0b + 8fd146c commit 201206f

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

tests/TestMslsGetSet.php

+6-6
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
class TestMslsGetSet extends MslsUnitTestCase {
88

9-
public function test_unset() {
9+
public function test_unset(): void {
1010
$obj = new MslsGetSet();
1111
$this->assertTrue( $obj->is_empty() );
1212

@@ -17,7 +17,7 @@ public function test_unset() {
1717
$this->assertTrue( $obj->is_empty() );
1818
}
1919

20-
public function test_set_empty() {
20+
public function test_set_empty(): void {
2121
$obj = new MslsGetSet();
2222
$this->assertTrue( $obj->is_empty() );
2323

@@ -28,7 +28,7 @@ public function test_set_empty() {
2828
$this->assertTrue( $obj->is_empty() );
2929
}
3030

31-
public function test_set() {
31+
public function test_set(): void {
3232
$obj = new MslsGetSet();
3333

3434
$obj->abc = 'test';
@@ -37,7 +37,7 @@ public function test_set() {
3737
$this->assertTrue( isset( $obj->abc ) );
3838
}
3939

40-
public function test_isset() {
40+
public function test_isset(): void {
4141
$obj = new MslsGetSet();
4242

4343
$this->assertTrue( $obj->is_empty() );
@@ -48,15 +48,15 @@ public function test_isset() {
4848
$this->assertEquals( 'test', $obj->abc );
4949
}
5050

51-
public function test_has_value() {
51+
public function test_has_value(): void {
5252
$obj = new MslsGetSet();
5353

5454
$obj->a_key = 'test';
5555

5656
$this->assertTrue( $obj->has_value( 'a_key' ) );
5757
}
5858

59-
public function test_get_array() {
59+
public function test_get_array(): void {
6060
$obj = new MslsGetSet();
6161

6262
$obj->temp = 'test';

tests/TestMslsLink.php

+5-5
Original file line numberDiff line numberDiff line change
@@ -7,27 +7,27 @@
77

88
class TestMslsLink extends MslsUnitTestCase {
99

10-
public function test_get_types() {
10+
public function test_get_types(): void {
1111
$this->assertCount( 4, MslsLink::get_types() );
1212
}
1313

14-
public function test_get_description() {
14+
public function test_get_description(): void {
1515
Functions\when( '__' )->returnArg();
1616

1717
$this->assertEquals( 'Flag and description', MslsLink::get_description() );
1818
}
1919

20-
public function test_get_types_description() {
20+
public function test_get_types_description(): void {
2121
Functions\when( '__' )->returnArg();
2222

2323
$this->assertCount( 4, MslsLink::get_types_description() );
2424
}
2525

26-
public function test_callback() {
26+
public function test_callback(): void {
2727
$this->assertEquals( '{Test}', MslsLink::callback( 'Test' ) );
2828
}
2929

30-
public function test_object2string_conversion() {
30+
public function test_object2string_conversion(): void {
3131
$obj = MslsLink::create( 0 );
3232

3333
$this->assertEquals( '<img src="{src}" alt="{alt}"/> {txt}', strval( $obj ) );

0 commit comments

Comments
 (0)