Skip to content

Instantly share code, notes, and snippets.

@MZAWeb
Created November 23, 2012 19:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save MZAWeb/4136893 to your computer and use it in GitHub Desktop.
Save MZAWeb/4136893 to your computer and use it in GitHub Desktop.
Testing
<?php
add_action( 'plugins_loaded', 'my_pre_my_ostrichcized_plugins', 1 );
add_action( 'wp', 'dd_test_notice' );
add_action( 'wp', 'dd_test_warning' );
add_action( 'wp', 'dd_test_fatal' );
function dd_test_notice() {
$error = NOT_DEFINED_CONSTANT;
}
function dd_test_warning() {
foreach ( null as $var ) {}
}
function dd_test_fatal() {
this_function_doesnt_exist();
}
function my_ostrichcized_plugins( $slugs ) {
$slugs[] = 'testing-errors';
return $slugs;
}
function my_pre_my_ostrichcized_plugins() {
add_filter( 'ostrichcized_plugins', 'my_ostrichcized_plugins' );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment