PHP code example of openbuildings / kohana-test-bootstrap

1. Go to this page and download the library: Download openbuildings/kohana-test-bootstrap library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

openbuildings / kohana-test-bootstrap example snippets




Kohana::modules(array(
	// Add some core kohaan modules
	'database' => MODPATH.'database',
	'cache'    => MODPATH.'cache',
	// Your own module - this is where the module you are testing will appear in kohana's cascading filesystem
	'functest' => __DIR__.'/..',
	// Any other kohana modules,  => 'localhost',
				'database'   => 'test-functest',
				'username'   => 'root',
				'password'   => '',
				'persistent' => TRUE,
			),
			'table_prefix' => '',
			'charset'      => 'utf8',
			'caching'      => FALSE,
		));
xml
<phpunit colors="true" bootstrap="tests/bootstrap.php">
	<testsuites>
		<testsuite>
			<directory>tests/tests</directory>
		</testsuite>
	</testsuites>
	<filter>
		<blacklist>
			<directory suffix=".php">vendor/</directory>
		</blacklist>
	</filter>
</phpunit>