diff --git b/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php a/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php index 4270b66..ca906ea 100644 --- b/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php +++ a/core/modules/block/lib/Drupal/block/Tests/Views/DisplayBlockTest.php @@ -219,7 +219,6 @@ public function testViewsBlockForm() { $edit['settings[override][items_per_page]'] = 5; $this->drupalPostForm('admin/structure/block/manage/views_block__test_view_block_block_1_4', $edit, t('Save block')); - $storage->resetCache(); $block = $storage->load('views_block__test_view_block_block_1_4'); $config = $block->getPlugin()->getConfiguration(); diff --git b/core/modules/ckeditor/lib/Drupal/ckeditor/Tests/CKEditorAdminTest.php a/core/modules/ckeditor/lib/Drupal/ckeditor/Tests/CKEditorAdminTest.php index 2b7474f..4b2e086 100644 --- b/core/modules/ckeditor/lib/Drupal/ckeditor/Tests/CKEditorAdminTest.php +++ a/core/modules/ckeditor/lib/Drupal/ckeditor/Tests/CKEditorAdminTest.php @@ -139,7 +139,6 @@ function testAdmin() { ); $this->drupalPostForm(NULL, $edit, t('Save configuration')); $expected_settings['plugins']['stylescombo']['styles'] = "h1.title|Title\np.callout|Callout\n\n"; - \Drupal::entityManager()->getStorage('editor')->resetCache(); $editor = entity_load('editor', 'filtered_html'); $this->assertTrue($editor instanceof Editor, 'An Editor config entity exists.'); $this->assertIdentical($expected_settings, $editor->settings, 'The Editor config entity has the correct settings.'); @@ -157,7 +156,6 @@ function testAdmin() { 'editor[settings][toolbar][button_groups]' => json_encode($expected_settings['toolbar']['rows']), ); $this->drupalPostForm(NULL, $edit, t('Save configuration')); - \Drupal::entityManager()->getStorage('editor')->resetCache(); $editor = entity_load('editor', 'filtered_html'); $this->assertTrue($editor instanceof Editor, 'An Editor config entity exists.'); $this->assertIdentical($expected_settings, $editor->settings, 'The Editor config entity has the correct settings.'); @@ -184,7 +182,6 @@ function testAdmin() { $ultra_llama_mode_checkbox = $this->xpath('//input[@type="checkbox" and @name="editor[settings][plugins][llama_contextual_and_button][ultra_llama_mode]" and @checked="checked"]'); $this->assertTrue(count($ultra_llama_mode_checkbox) === 1, 'The "Ultra llama mode" checkbox exists and is checked.'); $expected_settings['plugins']['llama_contextual_and_button']['ultra_llama_mode'] = 1; - \Drupal::entityManager()->getStorage('editor')->resetCache(); $editor = entity_load('editor', 'filtered_html'); $this->assertTrue($editor instanceof Editor, 'An Editor config entity exists.'); $this->assertIdentical($expected_settings, $editor->settings); diff --git b/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php a/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php index 2d77dd0..7442166 100644 --- b/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php +++ a/core/modules/contact/lib/Drupal/contact/Tests/ContactSitewideTest.php @@ -405,7 +405,6 @@ function deleteCategories() { else { $this->drupalPostForm("admin/structure/contact/manage/$id/delete", array(), t('Delete')); $this->assertRaw(t('Category %label has been deleted.', array('%label' => $category->label()))); - \Drupal::entityManager()->getStorage('contact_category')->resetCache(); $this->assertFalse(entity_load('contact_category', $id), format_string('Category %category not found', array('%category' => $category->label()))); } } diff --git b/core/modules/entity/lib/Drupal/entity/Tests/EntityDisplayTest.php a/core/modules/entity/lib/Drupal/entity/Tests/EntityDisplayTest.php index e153b45..31ea4e8 100644 --- b/core/modules/entity/lib/Drupal/entity/Tests/EntityDisplayTest.php +++ a/core/modules/entity/lib/Drupal/entity/Tests/EntityDisplayTest.php @@ -267,6 +267,8 @@ public function testRenameDeleteBundle() { entity_create('node_type', array('type' => 'article'))->save(); entity_get_display('node', 'article', 'default')->save(); entity_get_form_display('node', 'article', 'default')->save(); + + // Rename the article bundle and assert the entity display is renamed. $type = node_type_load('article'); $type->old_type = 'article'; $type->type = 'article_rename'; @@ -355,5 +357,3 @@ public function testDeleteFieldInstance() { } } - // Rename the article bundle and assert the entity display is renamed. - diff --git b/core/modules/field/field.info.inc a/core/modules/field/field.info.inc index 24d7eb5..8aba57b 100644 --- b/core/modules/field/field.info.inc +++ a/core/modules/field/field.info.inc @@ -39,11 +39,6 @@ function field_info_cache_clear() { \Drupal::service('plugin.manager.field.field_type')->clearCachedDefinitions(); \Drupal::service('config.factory')->reset(); - // Make sure that instantiated field definition and instance entities are - // cleared. - \Drupal::entityManager()->getStorage('field_config')->resetCache(); - \Drupal::entityManager()->getStorage('field_instance_config')->resetCache(); - Field::fieldInfo()->flush(); } diff --git b/core/modules/field/lib/Drupal/field/FieldInfo.php a/core/modules/field/lib/Drupal/field/FieldInfo.php index 936bb98..808a31b 100644 --- b/core/modules/field/lib/Drupal/field/FieldInfo.php +++ a/core/modules/field/lib/Drupal/field/FieldInfo.php @@ -162,9 +162,6 @@ public function flush() { $this->emptyBundles = array(); Cache::deleteTags(array('field_info' => TRUE)); - - \Drupal::entityManager()->getStorage('field_config')->resetCache(); - \Drupal::entityManager()->getStorage('field_instance_config')->resetCache(); } /** diff --git b/core/modules/field_ui/lib/Drupal/field_ui/Tests/ManageDisplayTest.php a/core/modules/field_ui/lib/Drupal/field_ui/Tests/ManageDisplayTest.php index 7b80479..1b8c16d 100644 --- b/core/modules/field_ui/lib/Drupal/field_ui/Tests/ManageDisplayTest.php +++ a/core/modules/field_ui/lib/Drupal/field_ui/Tests/ManageDisplayTest.php @@ -85,7 +85,6 @@ function testFormatterUI() { // Submit the form and check that the display is updated. $this->drupalPostForm(NULL, array(), t('Save')); - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); $display = entity_get_display('node', $this->type, 'default'); $display_options = $display->getComponent('field_test'); $current_format = $display_options['type']; @@ -180,7 +179,6 @@ public function testWidgetUI() { // Submit the form and check that the display is updated. $this->drupalPostForm(NULL, array(), t('Save')); - \Drupal::entityManager()->getStorage('entity_form_display')->resetCache(); $display = entity_get_form_display('node', $this->type, 'default'); $display_options = $display->getComponent('field_test'); $current_widget = $display_options['type']; @@ -382,8 +380,6 @@ function assertNodeViewNoText(EntityInterface $node, $view_mode, $text, $message function assertNodeViewTextHelper(EntityInterface $node, $view_mode, $text, $message, $not_exists) { // Make sure caches on the tester side are refreshed after changes // submitted on the tested side. - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); - \Drupal::entityManager()->getStorage('entity_form_display')->resetCache(); field_info_cache_clear(); // Save current content so that we can restore it when we're done. diff --git b/core/modules/filter/filter.module a/core/modules/filter/filter.module index 0c078d8..2e71d68 100644 --- b/core/modules/filter/filter.module +++ a/core/modules/filter/filter.module @@ -179,7 +179,6 @@ function filter_formats(AccountInterface $account = NULL) { function filter_formats_reset() { Cache::deleteTags(array('filter_formats' => TRUE)); drupal_static_reset('filter_formats'); - \Drupal::entityManager()->getStorage('filter_format')->resetCache(); } /** diff --git b/core/modules/filter/lib/Drupal/filter/Tests/FilterAdminTest.php a/core/modules/filter/lib/Drupal/filter/Tests/FilterAdminTest.php index 69034f7..248a9dd 100644 --- b/core/modules/filter/lib/Drupal/filter/Tests/FilterAdminTest.php +++ a/core/modules/filter/lib/Drupal/filter/Tests/FilterAdminTest.php @@ -178,7 +178,6 @@ function testFilterAdmin() { )); $this->assertTrue(!empty($elements), 'Reorder confirmed in admin interface.'); - \Drupal::entityManager()->getStorage('filter_format')->resetCache(); $filter_format = entity_load('filter_format', $restricted); foreach ($filter_format->filters() as $filter_name => $filter) { if ($filter_name == $second_filter || $filter_name == $first_filter) { diff --git b/core/modules/forum/lib/Drupal/forum/Tests/ForumTest.php a/core/modules/forum/lib/Drupal/forum/Tests/ForumTest.php index 3781896..6373929 100644 --- b/core/modules/forum/lib/Drupal/forum/Tests/ForumTest.php +++ a/core/modules/forum/lib/Drupal/forum/Tests/ForumTest.php @@ -335,9 +335,6 @@ function editForumVocabulary() { $this->assertResponse(200); $this->assertRaw(t('Updated vocabulary %name.', array('%name' => $edit['name'])), 'Vocabulary was edited'); - // Reset cache. - \Drupal::entityManager()->getStorage('taxonomy_vocabulary')->resetCache(); - // Grab the newly edited vocabulary. $current_vocabulary = entity_load('taxonomy_vocabulary', $vid); diff --git b/core/modules/image/lib/Drupal/image/Tests/ImageAdminStylesTest.php a/core/modules/image/lib/Drupal/image/Tests/ImageAdminStylesTest.php index d8bf9bf..bcad6fc 100644 --- b/core/modules/image/lib/Drupal/image/Tests/ImageAdminStylesTest.php +++ a/core/modules/image/lib/Drupal/image/Tests/ImageAdminStylesTest.php @@ -248,9 +248,6 @@ function testStyle() { // Delete the style. $this->drupalPostForm($style_path . '/delete', array(), t('Delete')); - // Reset cache. - \Drupal::entityManager()->getStorage('image_style')->resetCache(); - // Confirm the style directory has been removed. $directory = file_default_scheme() . '://styles/' . $style_name; $this->assertFalse(is_dir($directory), format_string('Image style %style directory removed on style deletion.', array('%style' => $style->label()))); diff --git b/core/modules/image/lib/Drupal/image/Tests/ImageFieldDefaultImagesTest.php a/core/modules/image/lib/Drupal/image/Tests/ImageFieldDefaultImagesTest.php index e3ad510..edf1919 100644 --- b/core/modules/image/lib/Drupal/image/Tests/ImageFieldDefaultImagesTest.php +++ a/core/modules/image/lib/Drupal/image/Tests/ImageFieldDefaultImagesTest.php @@ -233,9 +233,6 @@ public function testDefaultImages() { ) ); - // Reset cache. - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); - // Reload the nodes. $article_built = node_view($article = node_load($article->id(), TRUE)); $page_built = node_view($page = node_load($page->id(), TRUE)); @@ -271,9 +268,6 @@ public function testDefaultImages() { 'Updated article image field instance default has been successfully removed.' ); - // Reset cache. - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); - // Reload the nodes. $article_built = node_view($article = node_load($article->id(), TRUE)); $page_built = node_view($page = node_load($page->id(), TRUE)); diff --git b/core/modules/menu/lib/Drupal/menu/Tests/MenuTest.php a/core/modules/menu/lib/Drupal/menu/Tests/MenuTest.php index 7df6a7f..f984aa7 100644 --- b/core/modules/menu/lib/Drupal/menu/Tests/MenuTest.php +++ a/core/modules/menu/lib/Drupal/menu/Tests/MenuTest.php @@ -214,10 +214,6 @@ function deleteCustomMenu() { // Delete custom menu. $this->drupalPostForm("admin/structure/menu/manage/$menu_name/delete", array(), t('Delete')); - - // Reset cache. - \Drupal::entityManager()->getStorage('menu')->resetCache(); - $this->assertResponse(200); $this->assertRaw(t('The custom menu %title has been deleted.', array('%title' => $label)), 'Custom menu was deleted'); $this->assertFalse(menu_load($menu_name), 'Custom menu was deleted'); diff --git b/core/modules/options/lib/Drupal/options/Tests/OptionsFieldTest.php a/core/modules/options/lib/Drupal/options/Tests/OptionsFieldTest.php index cba75e3..a1d2c14 100644 --- b/core/modules/options/lib/Drupal/options/Tests/OptionsFieldTest.php +++ a/core/modules/options/lib/Drupal/options/Tests/OptionsFieldTest.php @@ -60,10 +60,6 @@ function testUpdateAllowedValues() { // Removed options do not appear. $this->field->settings['allowed_values'] = array(2 => 'Two'); $this->field->save(); - - // Reset cache. - \Drupal::entityManager()->getStorage('entity_form_display')->resetCache(); - $entity = entity_create('entity_test'); $form = \Drupal::service('entity.form_builder')->getForm($entity); $this->assertTrue(empty($form[$this->fieldName]['widget'][1]), 'Option 1 does not exist'); @@ -73,10 +69,6 @@ function testUpdateAllowedValues() { // Completely new options appear. $this->field->settings['allowed_values'] = array(10 => 'Update', 20 => 'Twenty'); $this->field->save(); - - // Reset cache. - \Drupal::entityManager()->getStorage('entity_form_display')->resetCache(); - // The entity holds an outdated field object with the old allowed values // setting, so we need to reintialize the entity object. $entity = entity_create('entity_test'); diff --git b/core/modules/path/lib/Drupal/path/Tests/PathLanguageTest.php a/core/modules/path/lib/Drupal/path/Tests/PathLanguageTest.php index 1ab0f09..a2fcbb7 100644 --- b/core/modules/path/lib/Drupal/path/Tests/PathLanguageTest.php +++ a/core/modules/path/lib/Drupal/path/Tests/PathLanguageTest.php @@ -67,9 +67,6 @@ function setUp() { ); $this->drupalPostForm('admin/config/regional/content-language', $edit, t('Save')); - // Reset cache. - \Drupal::entityManager()->getStorage('node')->resetCache(); - // Ensure configuration changes are picked up in the host environment. Field::fieldInfo()->flush(); $field = Field::fieldInfo()->getField('node', 'body'); @@ -143,9 +140,6 @@ function testAliasTranslation() { $edit = array('preferred_langcode' => 'fr'); $this->drupalPostForm("user/" . $this->web_user->id() . "/edit", $edit, t('Save')); - // Reset cache. - \Drupal::entityManager()->getStorage('node')->resetCache(); - // Check that the English alias works. In this situation French is the // current UI and content language, while URL language is English (since we // do not have a path prefix we fall back to the site's default language). diff --git b/core/modules/search/lib/Drupal/search/Tests/SearchRankingTest.php a/core/modules/search/lib/Drupal/search/Tests/SearchRankingTest.php index 5b9cbcc..5d16f80 100644 --- b/core/modules/search/lib/Drupal/search/Tests/SearchRankingTest.php +++ a/core/modules/search/lib/Drupal/search/Tests/SearchRankingTest.php @@ -125,7 +125,6 @@ public function testRankings() { $this->drupalGet('admin/config/search/settings/manage/node_search'); $this->assertTrue($this->xpath('//select[@id="edit-rankings-' . $node_rank . '"]//option[@value="10"]'), 'Select list to prioritize ' . $node_rank . ' for node ranks is visible and set to 10.'); - \Drupal::entityManager()->getStorage('search_page')->resetCache(array('node_search')); // Reload the plugin to get the up-to-date values. $this->nodeSearch = entity_load('search_page', 'node_search'); // Do the search and assert the results. diff --git b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php index 8b71d15..d1bd39c 100644 --- b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php +++ a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutLinksTest.php @@ -60,10 +60,6 @@ public function testShortcutLinkAdd() { ); $this->drupalPostForm('admin/config/user-interface/shortcut/manage/' . $set->id() . '/add-link', $form_data, t('Save')); $this->assertResponse(200); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $saved_set = shortcut_set_load($set->id()); $paths = $this->getShortcutInformation($saved_set, 'path'); $this->assertTrue(in_array($this->container->get('path.alias_manager')->getSystemPath($test['path']), $paths), 'Shortcut created: ' . $test['path']); @@ -114,10 +110,6 @@ public function testShortcutLinkRename() { $shortcuts = $set->getShortcuts(); $shortcut = reset($shortcuts); $this->drupalPostForm('admin/config/user-interface/shortcut/link/' . $shortcut->id(), array('title' => $new_link_name, 'path' => $shortcut->path->value), t('Save')); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $saved_set = shortcut_set_load($set->id()); $titles = $this->getShortcutInformation($saved_set, 'title'); $this->assertTrue(in_array($new_link_name, $titles), 'Shortcut renamed: ' . $new_link_name); @@ -136,10 +128,6 @@ public function testShortcutLinkChangePath() { $shortcuts = $set->getShortcuts(); $shortcut = reset($shortcuts); $this->drupalPostForm('admin/config/user-interface/shortcut/link/' . $shortcut->id(), array('title' => $shortcut->getTitle(), 'path' => $new_link_path), t('Save')); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $saved_set = shortcut_set_load($set->id()); $paths = $this->getShortcutInformation($saved_set, 'path'); $this->assertTrue(in_array($new_link_path, $paths), 'Shortcut path changed: ' . $new_link_path); @@ -168,10 +156,6 @@ public function testShortcutLinkDelete() { $shortcuts = $set->getShortcuts(); $shortcut = reset($shortcuts); $this->drupalPostForm('admin/config/user-interface/shortcut/link/' . $shortcut->id() . '/delete', array(), 'Delete'); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $saved_set = shortcut_set_load($set->id()); $ids = $this->getShortcutInformation($saved_set, 'id'); $this->assertFalse(in_array($shortcut->id(), $ids), 'Successfully deleted a shortcut.'); diff --git b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutSetsTest.php a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutSetsTest.php index b5dafbc..2a31535 100644 --- b/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutSetsTest.php +++ a/core/modules/shortcut/lib/Drupal/shortcut/Tests/ShortcutSetsTest.php @@ -31,10 +31,6 @@ function testShortcutSetAdd() { 'id' => strtolower($this->randomName()), ); $this->drupalPostForm(NULL, $edit, t('Save')); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $new_set = $this->container->get('entity.manager')->getStorage('shortcut_set')->load($edit['id']); $this->assertIdentical($new_set->id(), $edit['id'], 'Successfully created a shortcut set.'); $this->drupalGet('user/' . $this->admin_user->id() . '/shortcuts'); @@ -102,10 +98,6 @@ function testShortcutSetRename() { $this->drupalGet('admin/config/user-interface/shortcut'); $this->clickLink(t('Edit shortcut set')); $this->drupalPostForm(NULL, array('label' => $new_label), t('Save')); - - // Reset cache. - \Drupal::entityManager()->getStorage('shortcut_set')->resetCache(); - $set = shortcut_set_load($set->id()); $this->assertTrue($set->label() == $new_label, 'Shortcut set has been successfully renamed.'); } diff --git b/core/modules/text/lib/Drupal/text/Tests/TextFieldTest.php a/core/modules/text/lib/Drupal/text/Tests/TextFieldTest.php index 097d450..aecf257 100644 --- b/core/modules/text/lib/Drupal/text/Tests/TextFieldTest.php +++ a/core/modules/text/lib/Drupal/text/Tests/TextFieldTest.php @@ -82,7 +82,6 @@ function testTextFieldValidation() { */ function testTextfieldWidgets() { $this->_testTextfieldWidgets('text', 'text_textfield'); - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); $this->_testTextfieldWidgets('text_long', 'text_textarea'); } @@ -150,7 +149,6 @@ function _testTextfieldWidgets($field_type, $widget_type) { */ function testTextfieldWidgetsFormatted() { $this->_testTextfieldWidgetsFormatted('text', 'text_textfield'); - \Drupal::entityManager()->getStorage('entity_view_display')->resetCache(); $this->_testTextfieldWidgetsFormatted('text_long', 'text_textarea'); } diff --git b/core/modules/user/lib/Drupal/user/Tests/UserPermissionsTest.php a/core/modules/user/lib/Drupal/user/Tests/UserPermissionsTest.php index 4a337c6..ca3f04a 100644 --- b/core/modules/user/lib/Drupal/user/Tests/UserPermissionsTest.php +++ a/core/modules/user/lib/Drupal/user/Tests/UserPermissionsTest.php @@ -94,10 +94,6 @@ function testAdministratorRole() { // Aggregator depends on file module, enable that as well. $edit['modules[Field types][file][enable]'] = TRUE; $this->drupalPostForm('admin/modules', $edit, t('Save configuration')); - - // Reset cache. - \Drupal::entityManager()->getStorage('user_role')->resetCache(); - $this->assertTrue($this->admin_user->hasPermission('administer news feeds'), 'The permission was automatically assigned to the administrator role'); } diff --git b/core/modules/user/lib/Drupal/user/Tests/UserRoleAdminTest.php a/core/modules/user/lib/Drupal/user/Tests/UserRoleAdminTest.php index 9f9719d..5052571 100644 --- b/core/modules/user/lib/Drupal/user/Tests/UserRoleAdminTest.php +++ a/core/modules/user/lib/Drupal/user/Tests/UserRoleAdminTest.php @@ -64,10 +64,6 @@ function testRoleAdministration() { $edit = array('label' => $role_name); $this->drupalPostForm("admin/people/roles/manage/{$role->id()}", $edit, t('Save')); $this->assertRaw(t('Role %label has been updated.', array('%label' => $role_name))); - - // Reset cache. - \Drupal::entityManager()->getStorage('user_role')->resetCache(); - $new_role = entity_load('user_role', $old_name); $this->assertEqual($new_role->label(), $role_name, 'The role name has been successfully changed.'); diff --git b/core/modules/user/lib/Drupal/user/Tests/Views/AccessRoleUITest.php a/core/modules/user/lib/Drupal/user/Tests/Views/AccessRoleUITest.php index bb230c7..017c1a3 100644 --- b/core/modules/user/lib/Drupal/user/Tests/Views/AccessRoleUITest.php +++ a/core/modules/user/lib/Drupal/user/Tests/Views/AccessRoleUITest.php @@ -62,9 +62,7 @@ public function testAccessRoleUI() { $this->assertResponse(200); $this->drupalPostForm(NULL, array(), t('Save')); - $storage_controller = $entity_manager->getStorage('view'); - $storage_controller->resetCache(array('test_access_role')); - $view = $storage_controller->load('test_access_role'); + $view = $entity_manager->getStorage('view')->load('test_access_role'); $display = $view->getDisplay('default'); $this->assertEqual($display['display_options']['access']['options']['role'], array('custom_role' => 'custom_role')); diff --git b/core/modules/views/lib/Drupal/views/Tests/Handler/AreaViewTest.php a/core/modules/views/lib/Drupal/views/Tests/Handler/AreaViewTest.php index 04a55dc..a99a316 100644 --- b/core/modules/views/lib/Drupal/views/Tests/Handler/AreaViewTest.php +++ a/core/modules/views/lib/Drupal/views/Tests/Handler/AreaViewTest.php @@ -54,8 +54,6 @@ public function testViewArea() { $this->assertTrue(strpos($output, 'view-test-simple-argument') !== FALSE, 'The test view is correctly embedded.'); $view->destroy(); - \Drupal::entityManager()->getStorage('view')->resetCache(array('test_simple_argument')); - $view->setArguments(array(27)); $this->executeView($view); $output = $view->render(); diff --git b/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleTest.php a/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleTest.php index fbd1a07..b20afb6 100644 --- b/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleTest.php +++ a/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleTest.php @@ -75,9 +75,6 @@ public function testStyle() { $output = drupal_render($output); $this->assertTrue(strpos($output, $random_text) !== FALSE, 'Make sure that the rendering of the row plugin appears in the output of the view.'); - // Reset cache. - \Drupal::entityManager()->getStorage('view')->resetCache(); - // Test without row plugin support. $view = Views::getView('test_view'); $view->setDisplay(); diff --git b/core/modules/views/lib/Drupal/views/Views.php a/core/modules/views/lib/Drupal/views/Views.php index d067cba..daff41c 100644 --- b/core/modules/views/lib/Drupal/views/Views.php +++ a/core/modules/views/lib/Drupal/views/Views.php @@ -227,7 +227,7 @@ public static function getApplicableViews($type) { $result = array(); foreach (\Drupal::entityManager()->getStorage('view')->loadMultiple($entity_ids) as $view) { // Check each display to see if it meets the criteria and is enabled. - $executable = static::executableFactory()->get($view); + $executable = $view->getExecutable(); $executable->initDisplay(); foreach ($executable->displayHandlers as $id => $handler) { if (!empty($handler->definition[$type]) && $handler->isEnabled()) { diff --git b/core/modules/views_ui/lib/Drupal/views_ui/Tests/CustomBooleanTest.php a/core/modules/views_ui/lib/Drupal/views_ui/Tests/CustomBooleanTest.php index fe92bfd..1b40d9f 100644 --- b/core/modules/views_ui/lib/Drupal/views_ui/Tests/CustomBooleanTest.php +++ a/core/modules/views_ui/lib/Drupal/views_ui/Tests/CustomBooleanTest.php @@ -103,8 +103,6 @@ public function testCustomOption() { // Save the view. $this->drupalPostForm('admin/structure/views/view/test_view', array(), 'Save'); - // Reset cache. - \Drupal::entityManager()->getStorage('view')->resetCache(); $view = Views::getView('test_view'); $output = $view->preview(); $output = drupal_render($output); diff --git b/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayAttachmentTest.php a/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayAttachmentTest.php index 59ec7d8..5d71210 100644 --- b/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayAttachmentTest.php +++ a/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayAttachmentTest.php @@ -60,8 +60,6 @@ public function testAttachmentUI() { $this->assertEqual($result[0]->attributes()->title, t('Multiple displays')); $this->drupalPostForm(NULL, array(), t('Save')); - // Reset cache. - \Drupal::entityManager()->getStorage('view')->resetCache(); $view = Views::getView('test_attachment_ui'); $view->initDisplay(); $this->assertEqual(array_keys($view->displayHandlers->get('attachment_1')->getOption('displays')), array('default', 'page_1'), 'The attached displays got saved as expected'); diff --git b/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayExtenderUITest.php a/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayExtenderUITest.php index e8aea7f..388eb38 100644 --- b/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayExtenderUITest.php +++ a/core/modules/views_ui/lib/Drupal/views_ui/Tests/DisplayExtenderUITest.php @@ -46,9 +46,6 @@ public function testDisplayExtenderUI() { $this->drupalPostForm($display_option_url, array('test_extender_test_option' => $random_text), t('Apply')); $this->assertLink($random_text); $this->drupalPostForm(NULL, array(), t('Save')); - - // Reset cache. - \Drupal::entityManager()->getStorage('view')->resetCache(); $view = Views::getView($view->storage->id()); $view->initDisplay(); $this->assertEqual($view->display_handler->getOption('test_extender_test_option'), $random_text, 'Make sure that the display extender option got saved.'); diff --git b/core/modules/views_ui/lib/Drupal/views_ui/Tests/ViewEditTest.php a/core/modules/views_ui/lib/Drupal/views_ui/Tests/ViewEditTest.php index 69f215d..1693888 100644 --- b/core/modules/views_ui/lib/Drupal/views_ui/Tests/ViewEditTest.php +++ a/core/modules/views_ui/lib/Drupal/views_ui/Tests/ViewEditTest.php @@ -153,7 +153,6 @@ public function testPluginProviders() { // Save the plugin form, to change the plugin used. $this->drupalPostForm("admin/structure/views/nojs/display/test_view/default/$plugin_type", array($element_name => $plugin_options['value']), t('Apply')); $this->drupalPostForm('admin/structure/views/view/test_view', array(), t('Save')); - \Drupal::entityManager()->getStorage('view')->resetCache(array('test_view')); // Check the plugin provider. $view = Views::getView('test_view'); $displays = $view->storage->get('display');