2018-11-19 12:14:58 +00:00
|
|
|
<?php
|
2018-11-24 03:25:56 +00:00
|
|
|
namespace ActivityPub\Test;
|
|
|
|
|
2018-11-19 12:14:58 +00:00
|
|
|
use ActivityPub\ActivityPub;
|
2019-01-23 23:34:25 +00:00
|
|
|
use ActivityPub\Config\ActivityPubConfig;
|
2018-11-19 12:14:58 +00:00
|
|
|
|
|
|
|
$dbPath = dirname( __FILE__ ) . '/../db.sqlite';
|
|
|
|
if ( file_exists( $dbPath ) ) {
|
|
|
|
unlink( $dbPath );
|
|
|
|
}
|
2019-01-23 23:34:25 +00:00
|
|
|
$config = ActivityPubConfig::createBuilder()
|
|
|
|
->setDbConnectionParams( array(
|
2018-11-19 12:14:58 +00:00
|
|
|
'driver' => 'pdo_sqlite',
|
|
|
|
'path' => $dbPath,
|
2019-01-23 23:34:25 +00:00
|
|
|
) )
|
|
|
|
->build();
|
|
|
|
$activityPub = new ActivityPub( $config );
|
2018-11-19 12:14:58 +00:00
|
|
|
$activityPub->updateSchema();
|
|
|
|
?>
|