summaryrefslogtreecommitdiff
path: root/runtime/parsed_options_test.cc
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/parsed_options_test.cc')
-rw-r--r--runtime/parsed_options_test.cc15
1 files changed, 15 insertions, 0 deletions
diff --git a/runtime/parsed_options_test.cc b/runtime/parsed_options_test.cc
index 8873eb9c60..60a0837819 100644
--- a/runtime/parsed_options_test.cc
+++ b/runtime/parsed_options_test.cc
@@ -109,6 +109,7 @@ TEST_F(ParsedOptionsTest, ParsedOptions) {
EXPECT_FALSE(VLOG_IS_ON(startup));
EXPECT_FALSE(VLOG_IS_ON(third_party_jni));
EXPECT_FALSE(VLOG_IS_ON(threads));
+ EXPECT_PARSED_EQ(InstructionSet::kNone, Opt::SimulateInstructionSet);
auto&& properties_list = map.GetOrDefault(Opt::PropertiesList);
ASSERT_EQ(2U, properties_list.size());
@@ -181,4 +182,18 @@ TEST_F(ParsedOptionsTest, ParsedOptionsInstructionSet) {
}
}
+TEST_F(ParsedOptionsTest, ParsedOptionSimulateInstructionSet) {
+ RuntimeOptions options;
+ options.push_back(std::make_pair("--simulate-isa=arm64", nullptr));
+
+ RuntimeArgumentMap map;
+ bool parsed = ParsedOptions::Parse(options, false, &map);
+ ASSERT_TRUE(parsed);
+ ASSERT_NE(0u, map.Size());
+
+ using Opt = RuntimeArgumentMap;
+
+ EXPECT_PARSED_EQ(InstructionSet::kArm64, Opt::SimulateInstructionSet);
+}
+
} // namespace art