message: test: Change code parser tests to use full wasm modules
diff: @@ -627,8 +627,11 @@ TEST(parser, code_with_empty_expr_2_locals)
  // Func with 2x i32 locals, only 0x0b "end" instruction.
  const auto func_2_locals_bin = "01027f0b"_bytes;
  const auto code_bin = add_size_prefix(func_2_locals_bin);
  + const auto wasm_bin = bytes{wasm_prefix} + make_section(10, make_vec({code_bin}));
  - const auto [code_obj, end_pos1] = parse<Code>(code_bin.data());
  + const auto module = parse(wasm_bin);
  + ASSERT_EQ(module.codesec.size(), 1);
  + const auto& code_obj = module.codesec[0];
  EXPECT_EQ(code_obj.local_count, 2);
  ASSERT_EQ(code_obj.instructions.size(), 1);
  EXPECT_EQ(code_obj.instructions[0], Instr::end);
  @@ -640,8 +643,11 @@ TEST(parser, code_with_empty_expr_5_locals)
  // Func with 1x i64 + 4x i32 locals , only 0x0b "end" instruction.
  const auto func_5_locals_bin = "02017f047e0b"_bytes;
  const auto code_bin = add_size_prefix(func_5_locals_bin);
  + const auto wasm_bin = bytes{wasm_prefix} + make_section(10, make_vec({code_bin}));
  - const auto [code_obj, end_pos1] = parse<Code>(code_bin.data());
  + const auto module = parse(wasm_bin);
  + ASSERT_EQ(module.codesec.size(), 1);
  + const auto& code_obj = module.codesec[0];
  EXPECT_EQ(code_obj.local_count, 5);
  ASSERT_EQ(code_obj.instructions.size(), 1);
  EXPECT_EQ(code_obj.instructions[0], Instr::end);
  