hiphop-php /hphp/test/zend/bad/ext/intl/tests/resourcebundle_create.php

Language PHP Lines 36
MD5 Hash eba8083da78135aeedb5a0496e5cc9d4 Estimated Cost $444 (why?)
Repository git://github.com/facebook/hiphop-php.git View Raw File View Project SPDX
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<?php
	
include "resourcebundle.inc";

function ut_main() {
	$str_res = '';
	// all fine
	$r1 = ut_resourcebundle_create( 'root', BUNDLE );
	$str_res .= debug( $r1 );
	$str_res .= print_r( $r1['teststring'], true)."\n";

	// non-root one
	$r1 = ut_resourcebundle_create( 'es', BUNDLE );
	$str_res .= debug( $r1 );
	$str_res .= print_r( $r1['teststring'], true)."\n";

	// fall back
	$r1 = ut_resourcebundle_create( 'en_US', BUNDLE );
        $str_res .= debug( $r1 );
	$str_res .= print_r( $r1['testsring'], true);

	// fall out
	$r2 = ut_resourcebundle_create( 'en_US', BUNDLE, false );
        $str_res .= debug( $r2 );

	// missing
	$r3 = ut_resourcebundle_create( 'en_US', 'nonexisting' );
        $str_res .= debug( $r3 );
	
	return $str_res;
}

	include_once( 'ut_common.inc' );
	ut_run();
?>
Back to Top