summaryrefslogtreecommitdiff
path: root/zephyr/test/base32
diff options
context:
space:
mode:
authorPaul Fagerburg <pfagerburg@google.com>2020-10-23 18:10:48 -0600
committerCommit Bot <commit-bot@chromium.org>2020-10-28 19:41:00 +0000
commit53962368a6c70d4e2e885df211c96950c8b26d25 (patch)
tree52be883057ca1b1383b77d2fdad1ef4ae45eb258 /zephyr/test/base32
parent3c79b8fbb955f18fc02d1c33449056f0b154d6b5 (diff)
downloadchrome-ec-53962368a6c70d4e2e885df211c96950c8b26d25.tar.gz
test: support building base32 as a Zephyr test
With the Ztest API supported now, add the files to build the base32 unit test as a Zephyr test (instead of an EC test). BUG=b:168032590 BRANCH=None TEST=follow instructions in docs/ztest.md to build as a Zephyr test Signed-off-by: Paul Fagerburg <pfagerburg@google.com> Change-Id: I06dd7864f2de48aab5776950d4840f81728137f1 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2500465 Tested-by: Paul Fagerburg <pfagerburg@chromium.org> Reviewed-by: Jett Rink <jettrink@chromium.org> Commit-Queue: Paul Fagerburg <pfagerburg@chromium.org>
Diffstat (limited to 'zephyr/test/base32')
-rw-r--r--zephyr/test/base32/CMakeLists.txt7
-rw-r--r--zephyr/test/base32/prj.conf6
2 files changed, 13 insertions, 0 deletions
diff --git a/zephyr/test/base32/CMakeLists.txt b/zephyr/test/base32/CMakeLists.txt
new file mode 100644
index 0000000000..3db4cee753
--- /dev/null
+++ b/zephyr/test/base32/CMakeLists.txt
@@ -0,0 +1,7 @@
+# SPDX-License-Identifier: Apache-2.0
+
+cmake_minimum_required(VERSION 3.13.1)
+project(base32)
+find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
+
+target_sources(app PRIVATE ${PLATFORM_EC}/test/base32.c)
diff --git a/zephyr/test/base32/prj.conf b/zephyr/test/base32/prj.conf
new file mode 100644
index 0000000000..4d4bf11d07
--- /dev/null
+++ b/zephyr/test/base32/prj.conf
@@ -0,0 +1,6 @@
+# Copyright 2020 The Chromium OS Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+CONFIG_ZTEST=y
+CONFIG_PLATFORM_EC=y