Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Unified Diff: tests/pnacl_dynamic_loading/pll_loader_test.cc

Issue 1825893002: PNaCl Dynamic Linking: Added portable dependencies to shared objects. (Closed) Base URL: https://chromium.googlesource.com/native_client/src/native_client.git@master
Patch Set: Bumping Feature Version Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/pnacl_dynamic_loading/nacl.scons ('k') | tests/pnacl_dynamic_loading/pll_symbols_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/pnacl_dynamic_loading/pll_loader_test.cc
diff --git a/tests/pnacl_dynamic_loading/pll_loader_test.cc b/tests/pnacl_dynamic_loading/pll_loader_test.cc
index e2a657e855a1c01ea8b8a33dfa18ece6c9a9e791..7903076fdd5e0495bd703de0886075015679f68e 100644
--- a/tests/pnacl_dynamic_loading/pll_loader_test.cc
+++ b/tests/pnacl_dynamic_loading/pll_loader_test.cc
@@ -57,17 +57,20 @@ int main(int argc, char **argv) {
int *module_a_var = (int *) modset.GetSym("module_a_var");
ASSERT_EQ(module_a_var, NULL);
- modset.AddBySoname(module_a_soname);
+ ASSERT_NE(modset.AddBySoname(module_a_soname), NULL);
module_a_var = (int *) modset.GetSym("module_a_var");
ASSERT_NE(module_a_var, NULL);
ASSERT_EQ(*module_a_var, 2345);
- modset.AddBySoname(module_b_soname);
+ // Demonstrate that the same soname cannot be loaded multiple times.
+ ASSERT_EQ(modset.AddBySoname(module_a_soname), NULL);
+
+ ASSERT_NE(modset.AddBySoname(module_b_soname), NULL);
int *module_b_var = (int *) modset.GetSym("module_b_var");
ASSERT_NE(module_b_var, NULL);
ASSERT_EQ(*module_b_var, 1234);
- modset.AddBySoname(module_tls_soname);
+ ASSERT_NE(modset.AddBySoname(module_tls_soname), NULL);
modset.ResolveRefs();
« no previous file with comments | « tests/pnacl_dynamic_loading/nacl.scons ('k') | tests/pnacl_dynamic_loading/pll_symbols_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698