7#ifndef TEST_ARCCORE_COLLECTIONS_TESTARRAYCOMMON_H
8#define TEST_ARCCORE_COLLECTIONS_TESTARRAYCOMMON_H
14#include <gtest/gtest.h>
27using namespace Arccore;
35 IntSubClass() =
default;
37 friend bool operator==(
const IntSubClass& v,
Integer iv) {
return v.m_v == iv; }
38 friend bool operator==(
const IntSubClass& v1,
const IntSubClass& v2) {
return v1.m_v == v2.m_v; }
39 friend bool operator!=(
const IntSubClass& v1,
const IntSubClass& v2) {
return v1.m_v != v2.m_v; }
40 friend std::ostream& operator<<(std::ostream& o,
const IntSubClass& c)
50 IntSubClassNoPod() =
default;
51 explicit IntSubClassNoPod(
Integer v)
56 friend bool operator==(
const IntSubClassNoPod& v,
Integer iv) {
return v.m_v == iv; }
58 friend bool operator!=(
const IntSubClassNoPod& v1,
const IntSubClassNoPod& v2) {
return v1.m_v != v2.m_v; }
59 friend std::ostream& operator<<(std::ostream& o, IntSubClassNoPod c)
74#define ARCCORE_UT_CHECK(expr, message) \
76 throw Arccore::FatalErrorException((message))
101 IntPtrSubClass(
const IntPtrSubClass& v)
106 void operator=(
const IntPtrSubClass& v)
112 bool operator==(
Integer iv)
const
122template <
typename T>
inline void _checkSameInfoArray2(
const Array2<T>& a,
const Array2<T>& b)
124 ASSERT_EQ(a.allocator(), b.allocator());
126 ASSERT_EQ(a.dim1Size(), b.dim1Size());
127 ASSERT_EQ(a.dim2Size(), b.dim2Size());
Definitions and globals of Arccore.
Class representing a classic 2D array.
Integer totalNbElement() const
Total number of elements (dim1Size()*dim2Size()).
Int32 Integer
Type representing an integer.