1// Copyright 2014 The Android Open Source Project 2// 3// This software is licensed under the terms of the GNU General Public 4// License version 2, as published by the Free Software Foundation, and 5// may be copied, distributed, and modified under those terms. 6// 7// This program is distributed in the hope that it will be useful, 8// but WITHOUT ANY WARRANTY; without even the implied warranty of 9// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10// GNU General Public License for more details. 11 12#include "android/utils/host_bitness.h" 13 14#include <gtest/gtest.h> 15 16#include <stdio.h> 17 18TEST(HostBitness, android_getHostBitness) { 19 int host_bitness = android_getHostBitness(); 20 printf("Found host bitness: %d\n", host_bitness); 21 EXPECT_TRUE(host_bitness == 32 || host_bitness == 64) << 22 "Invalid host bitness: " << host_bitness; 23} 24