1 //===- LLVMTestBase.h - Test fixure for LLVM dialect tests ------*- C++ -*-===//
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
7 //===----------------------------------------------------------------------===//
9 // Test fixure for LLVM dialect tests.
11 //===----------------------------------------------------------------------===//
13 #ifndef MLIR_UNITTEST_DIALECT_LLVMIR_LLVMTESTBASE_H
14 #define MLIR_UNITTEST_DIALECT_LLVMIR_LLVMTESTBASE_H
16 #include "mlir/Dialect/LLVMIR/LLVMDialect.h"
17 #include "mlir/IR/MLIRContext.h"
18 #include "gtest/gtest.h"
20 class LLVMIRTest
: public ::testing::Test
{
22 LLVMIRTest() { context
.getOrLoadDialect
<mlir::LLVM::LLVMDialect
>(); }
24 mlir::MLIRContext context
;