Create auto. test target, add FakeIt Framework, define engine lib
Some checks reported errors
buildbot/freebsd Build done.
buildbot/alpine Build done.
buildbot/alpine ascendent Build done.
buildbot/freebsd ascendent Build done.
buildbot/Ascendent (Alpine) Build done.
buildbot/Ascendent (FreeBSD) Build done.

Close #5
Close #6
Close #7
This commit is contained in:
S David 2022-08-24 00:11:50 -04:00
parent a0dcc903e9
commit a760c274b9
7 changed files with 64 additions and 0 deletions

View File

@ -1,3 +1,7 @@
# Makefile.am
# Copyright © 2022 Saul D. Beniquez
# License: MPL2
srcdir = @srcdir@
VPATH = @srcdir@

View File

@ -1,3 +1,7 @@
# src/Makefile.am
# Copyright © 2022 Saul D. Beniquez
# License: MPL2
include src/engine/Makefile.am
include src/tests/Makefile.am
include src/game/Makefile.am

20
src/engine/Makefile.am Normal file
View File

@ -0,0 +1,20 @@
# engine/Makefile.am
# Copyright © 2022 Saul D. Beniquez
# License: MPL2
pkglib_LTLIBRARIES+=libengine.la
noinst_LTLIBRARIES+=libengine-test.la
engine_sources=src/engine/noop.c
engine_test_addl_sources=
libengine_la_SOURCES=$(engine_sources)
libengine_test_la_SOURCES=$(engine_sources) $(engine_test_addl_sources)
libengine_la_CXXFLAGS=$(SDL2_CFLAGS)
libengine_test_la_CXXFLAGS=$(SDL2_CFLAGS)
libengine_test_la_CPPFLAGS=$(AM_CPPFLAGS) -DUNIT_TEST=1_
include_HEADERS+=${srcdir}/src/engine/engine.hpp

16
src/engine/engine.hpp Normal file
View File

@ -0,0 +1,16 @@
/* engine.hpp
* Copyright © 2022 Saul D. Beniquez
* License: Mozilla Public License v. 2.0
*
* This Source Code Form is subject to the terms of the Mozilla Public License,
* v.2.0. If a copy of the MPL was not distributed with this file, You can
* obtain one at https://mozilla.org/MPL/2.0/.
*/
extern "C" {
void noop(void);
}
// clang-format off
// vim: set foldmethod=marker foldmarker=#region,#endregion textwidth=80 ts=8 sts=0 sw=8 noexpandtab ft=cpp.doxygen :

15
src/engine/noop.c Normal file
View File

@ -0,0 +1,15 @@
/* null.c
* Copyright © 2022 Saul D. Beniquez
* License: Mozilla Public License v. 2.0
*
* This Source Code Form is subject to the terms of the Mozilla Public License,
* v.2.0. If a copy of the MPL was not distributed with this file, You can
* obtain one at https://mozilla.org/MPL/2.0/.
*/
void noop(void)
{
;
}
// vim: set foldmethod=marker foldmarker=@{{,@}} textwidth=80 ts=8 sts=8 sw=8 autoindent smartindent cindent noexpandtab ft=c.doxygen :

View File

@ -1,3 +1,7 @@
# tests/Makefile.am
# Copyright © 2022 Saul D. Beniquez
# License: MPL2
TESTS=
check_PROGRAMS+= app-test
TESTS+=$(check_PROGRAMS)

1
third_party/FakeIt vendored Submodule

@ -0,0 +1 @@
Subproject commit 78ca536e6b32f11e2883d474719a447915e40005