Fix class_linker_test.
ClassLinker::FindClass now requires the calling thread to be attached. Also
improve the error reporting in Thread::Attach.
Change-Id: I95bae22288902a8c19a99c14ad66f3dbcca4a0b6
diff --git a/src/class_linker_test.cc b/src/class_linker_test.cc
index a4775f3..d755e3e 100644
--- a/src/class_linker_test.cc
+++ b/src/class_linker_test.cc
@@ -41,6 +41,9 @@
}
TEST(ClassLinker, FindClass) {
+ ASSERT_TRUE(Thread::Init());
+ ASSERT_TRUE(Thread::Attach() != NULL);
+
scoped_ptr<DexFile> dex(DexFile::OpenBase64(kMyClassDex));
ASSERT_TRUE(dex != NULL);