本文整理汇总了PHP中TestBase::setUp方法的典型用法代码示例。如果您正苦于以下问题:PHP TestBase::setUp方法的具体用法?PHP TestBase::setUp怎么用?PHP TestBase::setUp使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TestBase
的用法示例。
在下文中一共展示了TestBase::setUp方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setUp
/**
* Set up.
*/
function setUp()
{
parent::setUp();
$this->createRequest("debug_clear")->exec();
$r = $this->createRequest("new_address")->exec();
$this->address = $r["address"];
}
示例2: setUp
public function setUp()
{
parent::setUp();
// Set the languages
config()->set('translatable.locales', ['en', 'tr']);
$this->setUpNodeType();
}
示例3: setUp
public function setUp()
{
parent::setUp();
$this->path = FIXTURES . DS . 'tests';
$this->bootstrap = dirname(FIXTURES) . DS . 'bootstrap.php';
$this->phpunitWrapper = PARATEST_ROOT . '/bin/phpunit-wrapper';
}
示例4: setUp
public function setUp()
{
parent::setUp();
if (!self::$connectionSet) {
LudoDb::setConnectionType('PDO');
}
}
示例5: setUp
public function setUp()
{
parent::setUp();
$this->setUpNodeType();
NodeSource::flushEventListeners();
NodeSource::boot();
}
示例6: setUp
public function setUp()
{
parent::setUp();
// Let the current user do anything.
global $current_user;
$current_user->add_cap('promote_users');
}
示例7: setUp
public function setUp()
{
parent::setUp();
$g = new TestGame();
$g->drop()->yesImSure();
$g->createTable();
}
示例8: setUp
public function setUp()
{
parent::setUp();
$s = new Section();
$s->drop()->yesImSure();
$s->createTable();
}
示例9: setUp
public function setUp()
{
parent::setUp();
// We do this due to a bug
// otherwise helper is not loaded
app()->make('settings');
}
示例10: setUp
public function setUp()
{
parent::setUp();
LudoDB::setConnectionType('PDO');
$this->startTimer();
$person = new Person();
$person->deleteTableData();
}
示例11: setUp
/**
* {@inheritdoc}
*/
protected function setUp()
{
parent::setUp();
static::skipIfCodeCoverageNotEnabled();
$this->targetDir = str_replace('.', '_', uniqid('/tmp/paratest-', true));
$this->removeDirectory($this->targetDir);
mkdir($this->targetDir);
}
示例12: setUp
public function setUp()
{
parent::setUp();
$this->root = vfsStream::setup('root_dir', null, ['foo.txt' => 'foobar', 'bar.php' => '<?php echo "bar";']);
vfsStream::newFile('large.txt')->withContent(LargeFileContent::withMegabytes(100))->at($this->root);
app()['path.upload'] = vfsStream::url('root_dir') . '/upload';
$this->uploadService = app()->make('transit.upload');
}
示例13: setUp
public function setUp()
{
parent::setUp();
$p = new PersonForUtility();
if ($p->exists()) {
$p->drop()->yesImSure();
}
$p->createTable();
}
示例14: setUp
public function setUp()
{
parent::setUp();
$car = new Car();
$car->drop()->yesImSure();
$car->createTable();
$pr = new CarProperty();
$pr->drop()->yesImSure();
$pr->createTable();
}
示例15: setUp
public function setUp()
{
parent::setUp();
$c = new LudoDBCache();
$c->drop()->yesImSure();
$c->createTable();
$c = new Capital();
$c->drop()->yesImSure();
$c->createTable();
}