protected function SmsFrameworkViewsTest::setUp in SMS Framework 8
Same name and namespace in other branches
- 2.x tests/src/Kernel/SmsFrameworkViewsTest.php \Drupal\Tests\sms\Kernel\SmsFrameworkViewsTest::setUp()
- 2.1.x tests/src/Kernel/SmsFrameworkViewsTest.php \Drupal\Tests\sms\Kernel\SmsFrameworkViewsTest::setUp()
Parameters
bool $import_test_views: Should the views specified on the test class be imported. If you need to setup some additional stuff, like fields, you need to call false and then call createTestViews for your own.
Overrides ViewsKernelTestBase::setUp
File
- tests/
src/ Kernel/ SmsFrameworkViewsTest.php, line 56
Class
- SmsFrameworkViewsTest
- Tests SMS Framework integration with Views.
Namespace
Drupal\Tests\sms\KernelCode
protected function setUp($import_test_views = TRUE) {
parent::setUp($import_test_views);
$this
->installEntitySchema('user');
$this
->installEntitySchema('sms');
$this
->installEntitySchema('sms_result');
$this
->installEntitySchema('sms_report');
$this->smsProvider = $this->container
->get('sms.provider');
$this->gateway = $this
->createMemoryGateway();
$this
->setFallbackGateway($this->gateway);
ViewTestData::createTestViews(get_class($this), [
'sms_test_views',
]);
}