Skip to content

Commit e38109f

Browse files
committed
#1353 Give the make file include a name and comment with more meaning
Signed-off-by: Sven Strittmatter <sven.strittmatter@iteratec.com>
1 parent 054bd12 commit e38109f

4 files changed

Lines changed: 8 additions & 17 deletions

File tree

hooks.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ module = hook
2222
prefix = hook
2323
name = ${hook}
2424

25-
include ../../common.mk
25+
include ../../test-base.mk
2626
include ../../env-paths.mk
2727
## Telling the env-paths file where the root project dir is. This is done to allow the generation of the paths of the different project folders relative to where the makefile is being run from.
2828
## So BIN_DIR= $(PROJECT_DIR)/bin will be BIN_DIR=../../bin
@@ -55,4 +55,4 @@ integration-tests: ## 🩺 Start integration test for this module in the namespa
5555
@echo ".: 🩺 Starting integration test in kind namespace 'integration-tests'."
5656
kubectl -n integration-tests delete scans --all
5757
npm ci --prefix $(TESTS_HELPERS_DIR)
58-
cd $(hook-prefix) && npm ci && npm run test --package jest@$(JEST_VERSION)
58+
cd $(hook-prefix) && npm ci && npm run test --package jest@$(JEST_VERSION)

scanners.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
name = ${scanner}
2222

23-
include ../../common.mk
23+
include ../../test-base.mk
2424
include ../../env-paths.mk
2525
## Telling the env-paths file where the root project dir is. This is done to allow the generation of the paths of the different project folders relative to where the makefile is being run from.
2626
## So BIN_DIR= $(PROJECT_DIR)/bin will be BIN_DIR=../../bin

sdk.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
name = ${sdk}
2323
module = ${sdk}
24-
include ../../common.mk
24+
include ../../test-base.mk
2525
include ../../env-paths.mk
2626
## Telling the env-paths file where the root project dir is. This is done to allow the generation of the paths of the different project folders relative to where the makefile is being run from.
2727
## So BIN_DIR= $(PROJECT_DIR)/bin will be BIN_DIR=../../bin

common.mk renamed to test-base.mk

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,11 @@
55
# SPDX-License-Identifier: Apache-2.0
66
#
77
#
8-
# This Makefile is intended to be used for development and testing only.
9-
# For using this scanner/hook in production please use the helm chart.
10-
# See: <https://www.securecodebox.io/docs/getting-started/installation>
8+
# This include is a base test setup used for hooks, scanners, and SDKs.
119
#
12-
# This Makefile expects some additional software to be installed:
13-
# - git
14-
# - node + npm
15-
# - docker
16-
# - kind
17-
# - kubectl
18-
# - helm
19-
# - yq
20-
21-
include ./prerequisites.mk
10+
11+
# include must be two levels up because this file is included effectivity two levels deeper in the modules hierarchy.
12+
include ../../prerequisites.mk
2213

2314
# IMPORTANT: The body of conditionals MUST not be indented! Indentation result in
2415
# errors on macOS/FreeBSD because the line wil be interpreted as command which must

0 commit comments

Comments
 (0)