projects
/
urcu.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: urcu-wait: add missing futex.h include
[urcu.git]
/
tests
/
unit
/
test_get_max_cpuid_from_sysfs
diff --git
a/tests/unit/test_get_max_cpuid_from_sysfs
b/tests/unit/test_get_max_cpuid_from_sysfs
index 230a51cd5c5f9c4ec3b60c4af9fd9739db5a789b..ffd1e1c819c33b3af031600625220bef085f1b43 100755
(executable)
--- a/
tests/unit/test_get_max_cpuid_from_sysfs
+++ b/
tests/unit/test_get_max_cpuid_from_sysfs
@@
-1,4
+1,4
@@
-#!/
bin/
bash
+#!/
usr/bin/env
bash
# SPDX-License-Identifier: GPL-2.0-or-later
if [ "x${URCU_TESTS_SRCDIR:-}" != "x" ]; then
# SPDX-License-Identifier: GPL-2.0-or-later
if [ "x${URCU_TESTS_SRCDIR:-}" != "x" ]; then
@@
-44,46
+44,50
@@
test_get_max_cpuid_from_sysfs() {
rm -rf "$TESTDIR"
}
rm -rf "$TESTDIR"
}
-plan_tests $NUM_TESTS
+if [ "$URCU_TESTS_OS_TYPE" == "linux" ]; then
+ plan_tests $NUM_TESTS
-diag "get_max_cpuid_from_sysfs"
+
diag "get_max_cpuid_from_sysfs"
-test_data=(0 "cpu0")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(0 "cpu0")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(1 "cpu0" "cpu1")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(1 "cpu0" "cpu1")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(1 "cpu1" "cpu0")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(1 "cpu1" "cpu0")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(3 "cpu3")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(3 "cpu3")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(99 "cpu99")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(99 "cpu99")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(3 "cpu0" "cpu3")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(3 "cpu0" "cpu3")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(3 "cpufreq" "cpuidle" "cpu0" "cpu1" "cpu2" "cpu3")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(3 "cpufreq" "cpuidle" "cpu0" "cpu1" "cpu2" "cpu3")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(0 "cpu" "cpu0")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(0 "cpu" "cpu0")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(5 "cpu" "cpu5")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(5 "cpu" "cpu5")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(-1 "toto")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(-1 "toto")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(-1 "cpu")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(-1 "cpu")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(-1 "cpua" "cpud")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+
test_data=(-1 "cpua" "cpud")
+
test_get_max_cpuid_from_sysfs "${test_data[@]}"
-test_data=(-1 "cpufreq" "cpuidle")
-test_get_max_cpuid_from_sysfs "${test_data[@]}"
+ test_data=(-1 "cpufreq" "cpuidle")
+ test_get_max_cpuid_from_sysfs "${test_data[@]}"
+else
+ plan_skip_all "Linux specific tests."
+fi
This page took
0.02904 seconds
and
4
git commands to generate.