Changeset 38762 for trunk/tests/phpunit/tests/hooks/do_action.php
- Timestamp:
- 10/09/2016 01:11:14 AM (9 years ago)
- File:
-
- 1 edited
-
trunk/tests/phpunit/tests/hooks/do_action.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/tests/phpunit/tests/hooks/do_action.php
r38571 r38762 20 20 $callback = array( $a, 'action' ); 21 21 $hook = new WP_Hook(); 22 $tag = rand_str();22 $tag = __FUNCTION__; 23 23 $priority = rand( 1, 100 ); 24 24 $accepted_args = rand( 1, 100 ); 25 $arg = rand_str();25 $arg = __FUNCTION__ . '_arg'; 26 26 27 27 $hook->add_filter( $tag, $callback, $priority, $accepted_args ); … … 35 35 $callback = array( $a, 'filter' ); 36 36 $hook = new WP_Hook(); 37 $tag = rand_str();37 $tag = __FUNCTION__; 38 38 $priority = rand( 1, 100 ); 39 39 $accepted_args = rand( 1, 100 ); 40 $arg = rand_str();40 $arg = __FUNCTION__ . '_arg'; 41 41 42 42 $hook->add_filter( $tag, $callback, $priority, $accepted_args ); … … 53 53 $callback_two = array( $b, 'filter' ); 54 54 $hook = new WP_Hook(); 55 $tag = rand_str();55 $tag = __FUNCTION__; 56 56 $priority = rand( 1, 100 ); 57 57 $accepted_args = rand( 1, 100 ); 58 $arg = rand_str();58 $arg = __FUNCTION__ . '_arg'; 59 59 60 60 $hook->add_filter( $tag, $callback_one, $priority, $accepted_args ); … … 72 72 $callback_two = array( $b, 'filter' ); 73 73 $hook = new WP_Hook(); 74 $tag = rand_str();74 $tag = __FUNCTION__; 75 75 $priority = rand( 1, 100 ); 76 76 $accepted_args = rand( 1, 100 ); 77 $arg = rand_str();77 $arg = __FUNCTION__ . '_arg'; 78 78 79 79 $hook->add_filter( $tag, $callback_one, $priority, $accepted_args ); … … 88 88 $callback = array( $this, '_action_callback' ); 89 89 $hook = new WP_Hook(); 90 $tag = rand_str();90 $tag = __FUNCTION__; 91 91 $priority = rand( 1, 100 ); 92 92 $accepted_args = 0; 93 $arg = rand_str();93 $arg = __FUNCTION__ . '_arg'; 94 94 95 95 $hook->add_filter( $tag, $callback, $priority, $accepted_args ); … … 102 102 $callback = array( $this, '_action_callback' ); 103 103 $hook = new WP_Hook(); 104 $tag = rand_str();104 $tag = __FUNCTION__; 105 105 $priority = rand( 1, 100 ); 106 106 $accepted_args = 1; 107 $arg = rand_str();107 $arg = __FUNCTION__ . '_arg'; 108 108 109 109 $hook->add_filter( $tag, $callback, $priority, $accepted_args ); … … 116 116 $callback = array( $this, '_action_callback' ); 117 117 $hook = new WP_Hook(); 118 $tag = rand_str();118 $tag = __FUNCTION__; 119 119 $priority = rand( 1, 100 ); 120 120 $accepted_args = 1000; 121 $arg = rand_str();121 $arg = __FUNCTION__ . '_arg'; 122 122 123 123 $hook->add_filter( $tag, $callback, $priority, $accepted_args );
Note: See TracChangeset
for help on using the changeset viewer.