summaryrefslogtreecommitdiff
path: root/lldb/unittests
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/unittests')
-rw-r--r--lldb/unittests/Utility/ArchSpecTest.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/lldb/unittests/Utility/ArchSpecTest.cpp b/lldb/unittests/Utility/ArchSpecTest.cpp
index 43cec1f735cc..de3590b73bba 100644
--- a/lldb/unittests/Utility/ArchSpecTest.cpp
+++ b/lldb/unittests/Utility/ArchSpecTest.cpp
@@ -123,6 +123,12 @@ TEST(ArchSpecTest, TestSetTriple) {
EXPECT_STREQ("i686", AS.GetArchitectureName());
EXPECT_EQ(ArchSpec::eCore_x86_32_i686, AS.GetCore());
+ AS = ArchSpec();
+ EXPECT_TRUE(AS.SetTriple("msp430---elf"));
+ EXPECT_EQ(llvm::Triple::msp430, AS.GetTriple().getArch());
+ EXPECT_STREQ("msp430", AS.GetArchitectureName());
+ EXPECT_EQ(ArchSpec::eCore_msp430, AS.GetCore());
+
// Various flavors of invalid triples.
AS = ArchSpec();
EXPECT_FALSE(AS.SetTriple("unknown-unknown-unknown"));