[ Index ]

PHP Cross Reference of YOURLS

title

Body

[close]

/tests/tests/plugins/ -> actions.php (summary)

(no description)

File Size: 532 lines (16 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

Plugin_Actions_Tests:: (28 methods):
  test_add_action_funcname()
  test_remove_action()
  test_add_several_actions_default_priority()
  test_add_several_actions_random_priorities()
  test_remove_all_actions()
  test_remove_all_actions_random_prio()
  test_remove_only_actions_with_given_prio()
  test_do_action_funcname()
  test_do_action_several_times_and_count()
  test_add_action_create_function()
  test_do_action_create_function()
  test_add_action_within_class()
  test_do_action_within_class()
  test_add_action_within_class_array()
  test_do_action_within_class_array()
  test_add_action_within_class_instance()
  test_do_action_within_class_instance()
  test_add_action_class_and_array()
  test_add_action_closure()
  test_do_action_closure()
  test_function_must_exist_if_applied()
  test_do_action_no_params()
  test_do_action_1_params()
  test_do_action_2_params()
  test_has_action_return_values()
  test_get_actions()
  change_one_global()
  accept_multiple_params()


Class: Plugin_Actions_Tests  - X-Ref

Action related tests

test_add_action_funcname()   X-Ref
Check adding an action with a simple function name

Syntax tested: yourls_add_action( $hook, 'func_name' );

since: 0.1

test_remove_action()   X-Ref
Remove an action

since: 0.1

test_add_several_actions_default_priority()   X-Ref
Add several actions on the same hook

since: 0.1

test_add_several_actions_random_priorities()   X-Ref
Add several actions on the same hook with different priorities

since: 0.1

test_remove_all_actions()   X-Ref
Remove all actions on a hook

since: 0.1

test_remove_all_actions_random_prio()   X-Ref
Remove all actions with random priorities on a hook

since: 0.1

test_remove_only_actions_with_given_prio()   X-Ref
Remove all actions with specific priority

since: 0.1

test_do_action_funcname( $hook )   X-Ref
Check 'doing' an action hooked with a simple function name

since: 0.1

test_do_action_several_times_and_count()   X-Ref
Check we keep correct track of the number of time an action is done

since: 0.1

test_add_action_create_function()   X-Ref
Check adding an action with an anonymous function using create_function()

Syntax tested: yourls_add_action( $hook, create_function() );

since: 0.1

test_do_action_create_function( $hook )   X-Ref
Check 'doing' an action hooked with an anonymous function using create_function()

since: 0.1

test_add_action_within_class()   X-Ref
Check adding an action with function within class

Syntax tested: yourls_add_action( $hook, 'Class::Function' );

since: 0.1

test_do_action_within_class( $hook )   X-Ref
Check 'doing' an action hooked with function within class

since: 0.1

test_add_action_within_class_array()   X-Ref
Check adding an action with function within class using an array

Syntax tested: yourls_add_action( $hook, array( 'Class', 'Function' ) );

since: 0.1

test_do_action_within_class_array( $hook )   X-Ref
Check 'doing' an action hooked with function within class

since: 0.1

test_add_action_within_class_instance()   X-Ref
Check adding an action with function within class instance

Syntax tested: yourls_add_action( $hook, array( $class, 'function' ) );

since: 0.1

test_do_action_within_class_instance( $hook )   X-Ref
Check 'doing' an action hooked with function within class instance

since: 0.1

test_add_action_class_and_array()   X-Ref
Check that hooking to 'Class::Method' or array( 'Class', 'Method') is the same

since: 0.1

test_add_action_closure()   X-Ref
Check adding an action with anonymous function using closure

Syntax tested: yourls_add_action( $hook, function(){ // do stuff } );

since: 0.1

test_do_action_closure( $hook )   X-Ref
Check 'doing' an action hooked with anonymous function using closure

since: 0.1

test_function_must_exist_if_applied()   X-Ref
Check that applied function must exist

since: 0.1

test_do_action_no_params()   X-Ref
Test yourls_do_action() with multiple params

Note : this test will expectedly fail when YOURLS actions work the same as filters, see issue #1203

since: 0.1

test_do_action_1_params()   X-Ref
Test yourls_do_action() with multiple params

Note : this test will expectedly fail when YOURLS actions work the same as filters, see issue #1203

since: 0.1

test_do_action_2_params()   X-Ref
Test yourls_do_action() with multiple params

Note : this test will expectedly fail when YOURLS actions work the same as filters, see issue #1203

since: 0.1

test_has_action_return_values()   X-Ref
Check return values of yourls_has_action()


test_get_actions()   X-Ref
Check that yourls_get_actions() returns expected values


change_one_global()   X-Ref
Dummy function -- just modifies the value of a global var


accept_multiple_params( $args )   X-Ref
Dummy function -- echo in one line arguments passed




Generated: Tue Sep 27 05:10:01 2022 Cross-referenced by PHPXref 0.7.1