1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "ash/test/ash_interactive_ui_test_base.h"
7 #include "base/path_service.h"
8 #include "ui/aura/env.h"
9 #include "ui/base/resource/resource_bundle.h"
10 #include "ui/base/ui_base_paths.h"
11 #include "ui/gl/test/gl_surface_test_support.h"
16 AshInteractiveUITestBase::AshInteractiveUITestBase() {}
18 AshInteractiveUITestBase::~AshInteractiveUITestBase() {}
20 void AshInteractiveUITestBase::SetUp() {
21 gfx::GLSurfaceTestSupport::InitializeOneOff();
23 ui::RegisterPathProvider();
24 ui::ResourceBundle::InitSharedInstanceWithLocale(
25 "en-US", NULL
, ui::ResourceBundle::LOAD_COMMON_RESOURCES
);
26 base::FilePath resources_pack_path
;
27 PathService::Get(base::DIR_MODULE
, &resources_pack_path
);
29 resources_pack_path
.Append(FILE_PATH_LITERAL("resources.pak"));
30 ResourceBundle::GetSharedInstance().AddDataPackFromPath(
31 resources_pack_path
, ui::SCALE_FACTOR_NONE
);
32 aura::Env::CreateInstance(true);
34 test::AshTestBase::SetUp();
37 void AshInteractiveUITestBase::TearDown() {
38 test::AshTestBase::TearDown();
39 aura::Env::DeleteInstance();