This source file includes following definitions.
- SetUp
- TearDown
- TEST_F
#include "remoting/base/resources.h"
#include "remoting/base/string_resources.h"
#include "ui/base/l10n/l10n_util.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace remoting {
class ResourcesTest : public testing::Test {
protected:
ResourcesTest(): resources_available_(false) {
}
virtual void SetUp() OVERRIDE {
resources_available_ = LoadResources("en-US");
}
virtual void TearDown() OVERRIDE {
UnloadResources();
}
bool resources_available_;
};
TEST_F(ResourcesTest, DISABLED_ProductName) {
#if defined(GOOGLE_CHROME_BUILD)
std::string expected_product_name = "Chrome Remote Desktop";
#else
std::string expected_product_name = "Chromoting";
#endif
#if defined(OS_WIN)
EXPECT_FALSE(resources_available_);
#else
EXPECT_TRUE(resources_available_);
#endif
if (resources_available_) {
EXPECT_EQ(expected_product_name,
l10n_util::GetStringUTF8(IDS_PRODUCT_NAME));
}
}
}