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

Unified Diff: test/unittests/wasm/module-decoder-unittest.cc

Issue 2454503005: [wasm] Support for restricted table imports. (Closed)
Patch Set: Fix GC stress issue; tables weren't being reset correctly Created 4 years, 2 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 | « test/mjsunit/wasm/wasm-module-builder.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/unittests/wasm/module-decoder-unittest.cc
diff --git a/test/unittests/wasm/module-decoder-unittest.cc b/test/unittests/wasm/module-decoder-unittest.cc
index 724d9ccf6d9d7b68dedbfd3e138fe25abf05429c..542c3c9d428bec2d4125501b51a5f3f6d69e262f 100644
--- a/test/unittests/wasm/module-decoder-unittest.cc
+++ b/test/unittests/wasm/module-decoder-unittest.cc
@@ -510,8 +510,7 @@ TEST_F(WasmModuleVerifyTest, OneIndirectFunction) {
EXPECT_EQ(1, result.val->signatures.size());
EXPECT_EQ(1, result.val->functions.size());
EXPECT_EQ(1, result.val->function_tables.size());
- EXPECT_EQ(1, result.val->function_tables[0].values.size());
- EXPECT_EQ(-1, result.val->function_tables[0].values[0]);
+ EXPECT_EQ(1, result.val->function_tables[0].min_size);
}
if (result.val) delete result.val;
}
@@ -537,8 +536,7 @@ TEST_F(WasmModuleVerifyTest, OneIndirectFunction_one_entry) {
EXPECT_EQ(1, result.val->signatures.size());
EXPECT_EQ(1, result.val->functions.size());
EXPECT_EQ(1, result.val->function_tables.size());
- EXPECT_EQ(1, result.val->function_tables[0].values.size());
- EXPECT_EQ(0, result.val->function_tables[0].values[0]);
+ EXPECT_EQ(1, result.val->function_tables[0].min_size);
}
if (result.val) delete result.val;
}
@@ -575,10 +573,7 @@ TEST_F(WasmModuleVerifyTest, MultipleIndirectFunctions) {
EXPECT_EQ(2, result.val->signatures.size());
EXPECT_EQ(4, result.val->functions.size());
EXPECT_EQ(1, result.val->function_tables.size());
- EXPECT_EQ(8, result.val->function_tables[0].values.size());
- for (int i = 0; i < 8; i++) {
- EXPECT_EQ(i & 3, result.val->function_tables[0].values[i]);
- }
+ EXPECT_EQ(8, result.val->function_tables[0].min_size);
}
if (result.val) delete result.val;
}
« no previous file with comments | « test/mjsunit/wasm/wasm-module-builder.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698