當前位置: 首頁>>代碼示例>>PHP>>正文


PHP UnitTester::seeRecord方法代碼示例

本文整理匯總了PHP中UnitTester::seeRecord方法的典型用法代碼示例。如果您正苦於以下問題:PHP UnitTester::seeRecord方法的具體用法?PHP UnitTester::seeRecord怎麽用?PHP UnitTester::seeRecord使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在UnitTester的用法示例。


在下文中一共展示了UnitTester::seeRecord方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: testUserAdd

 public function testUserAdd()
 {
     $user = factory(User::class, 'valid-user')->make();
     $values = ['first_name' => $user->first_name, 'last_name' => $user->last_name, 'email' => $user->email, 'username' => $user->username, 'password' => $user->password];
     User::create($values);
     $this->tester->seeRecord('users', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:UserTest.php

示例2: testLostStatuslabelAdd

 public function testLostStatuslabelAdd()
 {
     $statuslabel = factory(Statuslabel::class, 'lost')->make();
     $values = ['name' => $statuslabel->name];
     Statuslabel::create($values);
     $this->tester->seeRecord('status_labels', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:StatuslabelTest.php

示例3: testManufacturerAdd

 public function testManufacturerAdd()
 {
     $manufacturers = factory(Manufacturer::class, 'manufacturer')->make();
     $values = ['name' => $manufacturers->name];
     Manufacturer::create($values);
     $this->tester->seeRecord('manufacturers', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:ManufacturerTest.php

示例4: testAssetAdd

 public function testAssetAdd()
 {
     $location = factory(Location::class, 'location')->make();
     $values = ['name' => $location->name];
     Location::create($values);
     $this->tester->seeRecord('locations', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:LocationTest.php

示例5: testConsumableAdd

 public function testConsumableAdd()
 {
     $consumable = factory(Consumable::class, 'consumable')->make();
     $values = ['name' => $consumable->name, 'qty' => $consumable->qty, 'category_id' => $consumable->category_id, 'company_id' => $consumable->company_id];
     Consumable::create($values);
     $this->tester->seeRecord('consumables', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:ConsumableTest.php

示例6: testAccessoryAdd

 public function testAccessoryAdd()
 {
     $accessory = factory(Accessory::class, 'accessory')->make();
     $values = ['name' => $accessory->name, 'category_id' => $accessory->category_id, 'qty' => $accessory->qty];
     Accessory::create($values);
     $this->tester->seeRecord('accessories', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:AccessoryTest.php

示例7: testDepreciationAdd

 public function testDepreciationAdd()
 {
     $depreciations = factory(Depreciation::class, 'depreciation')->make();
     $values = ['name' => $depreciations->name, 'months' => $depreciations->months];
     Depreciation::create($values);
     $this->tester->seeRecord('depreciations', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:DepreciationTest.php

示例8: testSupplierAdd

 public function testSupplierAdd()
 {
     $supplier = factory(Supplier::class, 'supplier')->make();
     $values = ['name' => $supplier->name];
     Supplier::create($values);
     $this->tester->seeRecord('suppliers', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:SupplierTest.php

示例9: testRoleCanBeCreated

 public function testRoleCanBeCreated()
 {
     $role = new \ChopBox\Role();
     $role->role_name = "admin";
     $role->save();
     $this->tester->seeRecord('roles', ['role_name' => 'admin']);
 }
開發者ID:andela,項目名稱:chopbox,代碼行數:7,代碼來源:RoleTest.php

示例10: testAssetAdd

 public function testAssetAdd()
 {
     $asset = factory(Asset::class, 'asset')->make();
     $values = ['name' => $asset->name, 'model_id' => $asset->model_id, 'status_id' => $asset->status_id, 'asset_tag' => $asset->asset_tag];
     Asset::create($values);
     $this->tester->seeRecord('assets', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:AssetTest.php

示例11: testAccessoryCategoryAdd

 public function testAccessoryCategoryAdd()
 {
     $category = factory(Category::class, 'accessory-category')->make();
     $values = ['name' => $category->name, 'category_type' => $category->category_type];
     Category::create($values);
     $this->tester->seeRecord('categories', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:CategoryTest.php

示例12: testLostStatuslabelAdd

 public function testLostStatuslabelAdd()
 {
     $statuslabel = factory(Statuslabel::class, 'lost')->make();
     $values = ['name' => $statuslabel->name, 'deployable' => $statuslabel->deployable, 'pending' => $statuslabel->pending, 'archived' => $statuslabel->archived];
     Statuslabel::create($values);
     $this->tester->seeRecord('status_labels', $values);
 }
開發者ID:stijni,項目名稱:snipe-it,代碼行數:7,代碼來源:StatuslabelTest.php

示例13: testAssetModelAdd

 public function testAssetModelAdd()
 {
     $assetmodel = factory(AssetModel::class, 'assetmodel')->make();
     $values = ['name' => $assetmodel->name, 'manufacturer_id' => $assetmodel->manufacturer_id, 'category_id' => $assetmodel->category_id, 'eol' => $assetmodel->eol];
     AssetModel::create($values);
     $this->tester->seeRecord('models', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:AssetModelTest.php

示例14: testAssetAdd

 public function testAssetAdd()
 {
     $company = factory(Company::class, 'company')->make();
     $values = ['name' => $company->name];
     Company::create($values);
     $this->tester->seeRecord('companies', $values);
 }
開發者ID:dmeltzer,項目名稱:snipe-it,代碼行數:7,代碼來源:CompanyTest.php

示例15: testRegister

 public function testRegister()
 {
     $email = 'johndoe@example.com';
     $name = 'John Doe';
     $password = Hash::make('password');
     User::register(['email' => $email, 'password' => $password, 'name' => $name]);
     $this->tester->seeRecord('users', ['email' => $email, 'password' => $password, 'name' => $name]);
 }
開發者ID:ashwanibhasin,項目名稱:laravel5-starter,代碼行數:8,代碼來源:UserTest.php


注:本文中的UnitTester::seeRecord方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。