1 /*
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 
27 namespace android {
28 
29 class HashCombineTest : public testing::Test {
30 protected:
31 };
32 
TEST_F(HashCombineTest,Basics)33 TEST_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
44