Index: wordpress/wp-includes/functions.php
===================================================================
--- wordpress/wp-includes/functions.php	(revision 12788)
+++ wordpress/wp-includes/functions.php	(working copy)
@@ -2485,12 +2485,14 @@
  * @param string $title Error title.
  * @param string|array $args Optional arguements to control behaviour.
  */
-function wp_die( $message, $title = '', $args = array() ) {
+function wp_die( $message='', $title = '', $args = array() ) {
 	global $wp_locale;
 
 	$defaults = array( 'response' => 500 );
 	$r = wp_parse_args($args, $defaults);
-
+	
+	do_action( 'wp_die_call', $message, $title, $r );
+	
 	$have_gettext = function_exists('__');
 
 	if ( function_exists( 'is_wp_error' ) && is_wp_error( $message ) ) {
Index: wp-test.php
===================================================================
--- wp-test.php	(revision 287)
+++ wp-test.php	(working copy)
@@ -73,6 +73,14 @@
 // make sure we're installed
 assert(true == is_blog_installed());
 
+// register exception on wp_die to make it test-able 
+add_action('wp_die_call', array('wp_die_exception', 'hook'), 1, 3);
+class wp_die_exception extends Exception {
+	static function hook($message, $title, $args) {
+		throw new wp_die_exception(sprintf('Died. %s', print_r($message, true)));		
+	}
+}
+
 // include plugins for testing, if any
 if (is_dir(DIR_TESTPLUGINS)) {
 	$plugins = glob(realpath(DIR_TESTPLUGINS).'/*.php');
