Completed
Push — master ( 6c0735...dd8543 )
by Dennis
06:47
created

WP_Test_MslsPlugin::test_uninstall_method()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 0
loc 3
rs 10
c 0
b 0
f 0
1
<?php
2
/**
3
 * Tests for MslsPlugin
4
 *
5
 * @author Dennis Ploetner <[email protected]>
6
 * @package Msls
7
 */
8
9
use lloc\Msls\MslsPlugin;
10
use lloc\Msls\MslsOptions;
11
12
/**
13
 * WP_Test_MslsPlugin
14
 */
15
class WP_Test_MslsPlugin extends Msls_UnitTestCase {
16
17
	function get_test() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
18
		$options = MslsOptions::instance();
19
20
		return new MslsPlugin( $options );
21
	}
22
23
	/**
24
	 * Verify the static init-method
25
	 */
26
	function test_admin_menu_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
27
		$this->assertInternalType( 'boolean', $this->get_test()->admin_menu() );
28
	}
29
30
	/**
31
	 * Verify the static init_widget-method
32
	 */
33
	function test_init_widget_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
34
		$this->assertInternalType( 'boolean', $this->get_test()->init_widget() );
35
	}
36
37
	/**
38
	 * Verify the static init_i18n_support-method
39
	 */
40
	function test_init_i18n_support_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
41
		$this->assertInternalType( 'boolean', $this->get_test()->init_i18n_support() );
42
	}
43
44
	/**
45
	 * Verify the static message_handler-method
46
	 */
47
	function test_message_handler_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
48
		$this->expectOutputString( '<div id="msls-warning" class="error"><p>Test</p></div>' );
49
		MslsPlugin::message_handler( 'Test' );
50
	}
51
52
	/**
53
	 * Verify the static uninstall-method
54
	 */
55
	function test_uninstall_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
56
		$this->assertInternalType( 'boolean', $this->get_test()->uninstall() );
57
	}
58
59
	/**
60
	 * Verify the static cleanup-method
61
	 */
62
	function test_cleanup_method() {
0 ignored issues
show
Best Practice introduced by
It is generally recommended to explicitly declare the visibility for methods.

Adding explicit visibility (private, protected, or public) is generally recommend to communicate to other developers how, and from where this method is intended to be used.

Loading history...
63
		$this->assertInternalType( 'boolean', MslsPlugin::cleanup() );
64
	}
65
66
}
67