[Windows] Add missing testing namespace (flutter/engine#35131)

flutter_windows_unittests.cc had its tests inside the flutter namespace
rather than the flutter:testing namespace. This adds the missing
namespace and makes one namespace-related cleanup in one of the key
event unit tests as well.

This is a post-landing cleanup for PR:
https://github.com/flutter/engine/pull/35106

Issue: https://github.com/flutter/flutter/issues/86617
This commit is contained in:
Chris Bracken 2022-08-03 20:26:44 +01:00 committed by GitHub
parent 0ddf909903
commit 3e485ec15e
2 changed files with 5 additions and 6 deletions

View File

@ -9,6 +9,7 @@
#include "gtest/gtest.h"
namespace flutter {
namespace testing {
TEST(FlutterWindowsTest, GetTextureRegistrar) {
FlutterDesktopEngineProperties properties;
@ -22,4 +23,5 @@ TEST(FlutterWindowsTest, GetTextureRegistrar) {
FlutterDesktopEngineDestroy(engine);
}
} // namespace testing
} // namespace flutter

View File

@ -14,6 +14,7 @@
#include "gtest/gtest.h"
namespace flutter {
namespace testing {
namespace {
@ -71,11 +72,6 @@ UINT DefaultMapVkToScan(UINT virtual_key, bool extended) {
extended ? MAPVK_VK_TO_VSC_EX : MAPVK_VK_TO_VSC);
}
} // namespace
namespace testing {
namespace {
constexpr uint64_t kScanCodeKeyA = 0x1e;
constexpr uint64_t kScanCodeAltLeft = 0x38;
constexpr uint64_t kScanCodeNumpad1 = 0x4f;
@ -86,9 +82,10 @@ constexpr uint64_t kScanCodeShiftRight = 0x36;
constexpr uint64_t kVirtualKeyA = 0x41;
using namespace ::flutter::testing::keycodes;
} // namespace
using namespace ::flutter::testing::keycodes;
TEST(KeyboardKeyEmbedderHandlerTest, ConvertChar32ToUtf8) {
std::string result;