chromium/v8/test/unittests/wasm/wasm-disassembler-unittest.cc

// Copyright 2022 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include <regex>
#include <string>

#include "src/base/vector.h"
#include "src/wasm/module-decoder.h"
#include "src/wasm/string-builder-multiline.h"
#include "src/wasm/wasm-disassembler-impl.h"
#include "test/unittests/test-utils.h"
#include "testing/gtest/include/gtest/gtest.h"

namespace v8 {
namespace internal {
namespace wasm {

class WasmDisassemblerTest : public ::v8::TestWithPlatform {};

// Code that is shared for all tests, the only difference is the input module
// and expected disassembler output.
void CheckDisassemblerOutput(base::Vector<const uint8_t> module_bytes,
                             std::string expected_output) {}

TEST_F(WasmDisassemblerTest, Mvp) {}

TEST_F(WasmDisassemblerTest, Names) {}

TEST_F(WasmDisassemblerTest, InvalidNameSection) {}

TEST_F(WasmDisassemblerTest, Simd) {}

TEST_F(WasmDisassemblerTest, Gc) {}

TEST_F(WasmDisassemblerTest, TooManyends) {}

TEST_F(WasmDisassemblerTest, Stringref) {}

TEST_F(WasmDisassemblerTest, Exnref) {}

// TODO(dlehmann): Add tests for the following Wasm features and extensions:
// - custom name section for Wasm GC constructs (struct and array type names,
// struct fields).
// - exception-related instructions (try, catch, catch_all, delegate) and named
// exception tags.
// - atomic instructions (threads proposal, 0xfe prefix).
// - some "numeric" instructions (0xfc prefix).

}  // namespace wasm
}  // namespace internal
}  // namespace v8