blob: 96c6e815887bc628b3b59131138ee66118b77221 [file] [log] [blame]
Dan Stozaa3d8f052020-09-29 13:37:23 -07001/*
2 * Copyright 2021 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#define LOG_TAG "HashCombineTest"
18
19#include <math.h>
20#include <stdlib.h>
21
22#include <math/half.h>
23#include <math/vec4.h>
24
25#include <gtest/gtest.h>
26
27namespace android {
28
29class HashCombineTest : public testing::Test {
30protected:
31};
32
33TEST_F(HashCombineTest, Basics) {
34 char a = 40;
35 int b = 32;
36 int c = 55;
37 float d = 42.f;
38 float d_ = 42.1f;
39
40 EXPECT_NE(hashCombine(a, b, c, d), hashCombine(a, b, c, d_));
41}
42
43}; // namespace android