blob: cba26bca7a55ad6ce0bc1e6a3d9e36ec2b855d9f [file] [log] [blame]
Sean Condonaf0eb3c2021-09-19 20:14:29 +01001# SPDX-FileCopyrightText: 2021-present Open Networking Foundation <info@opennetworking.org>
Scott Baker69654392021-09-17 13:50:16 -07002#
3# SPDX-License-Identifier: LicenseRef-ONF-Member-Only-1.0
4
5.PHONY: all test clean
6
Scott Baker69654392021-09-17 13:50:16 -07007all: test
8
Ray Milkey35a07f82021-10-26 15:05:43 -07009test: # @HELP run the acceptance tests
PUSHP RAJba2e32f2021-11-02 10:39:24 +000010test: deps yang-lint
Ray Milkey35a07f82021-10-26 15:05:43 -070011
12roc-test: # @HELP run the integration tests
13roc-test: deps # @HELP run the integration tests
Sean Condonaf0eb3c2021-09-19 20:14:29 +010014 ./build/bin/run-roc-test
Scott Baker69654392021-09-17 13:50:16 -070015
Sean Condonaf0eb3c2021-09-19 20:14:29 +010016clean: # @HELP clean up temporary files for ROC umbrella.
17 rm -rf aether-roc-umbrella/charts aether-roc-umbrella/Chart.lock
Scott Baker69654392021-09-17 13:50:16 -070018
Sean Condonaf0eb3c2021-09-19 20:14:29 +010019deps: # @HELP build dependencies for ROC Umbrella local charts.
Scott Baker69654392021-09-17 13:50:16 -070020deps: clean
Sean Condonaf0eb3c2021-09-19 20:14:29 +010021 helm dep build aether-roc-umbrella
Scott Baker69654392021-09-17 13:50:16 -070022
Sean Condonb0769e62021-12-21 09:57:29 +000023deps-chronos: # @HELP build dependencies for Chronos Umbrella local charts.
24deps-chronos: clean
25 rm -rf chronos-umbrella/Chart.lock chronos-umbrella/charts
26 helm dep build chronos-umbrella
27
Scott Baker69654392021-09-17 13:50:16 -070028help:
29 @grep -E '^.*: *# *@HELP' $(MAKEFILE_LIST) \
30 | sort \
31 | awk ' \
32 BEGIN {FS = ": *# *@HELP"}; \
33 {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}; \
34 '
PUSHP RAJba2e32f2021-11-02 10:39:24 +000035
Ray Milkeyedba2462021-12-30 10:59:09 -080036pyang:
37 pyang -v || pip install pyang
38
39yang-lint: pyang
PUSHP RAJba2e32f2021-11-02 10:39:24 +000040 pyang --lint ./config-models/aether-1.x/files/yang/*.yang
Sean Condondccb3142022-01-10 14:36:16 +000041 pyang --lint --lint-ensure-hyphenated-names -W error ./config-models/aether-2.0.x/files/yang/*.yang -p ./config-models/aether-2.0.x/files/yang
PUSHP RAJba2e32f2021-11-02 10:39:24 +000042 pyang --lint ./config-models/aether-2.1.x/files/yang/*.yang
43 pyang --lint ./config-models/aether-2.2.x/files/yang/*.yang
44 pyang --lint ./config-models/aether-3.x/files/yang/*.yang
PUSHP RAJe7e8d4f2021-11-22 12:10:45 +000045 pyang --lint --lint-ensure-hyphenated-names -W error ./config-models/aether-4.x/files/yang/*.yang -p ./config-models/aether-4.x/files/yang
46 pyang --lint --lint-ensure-hyphenated-names -W error ./config-models/plproxy-1.x/files/yang/*.yang -p ./config-models/plproxy-1.x/files/yang
Sean Condondccb3142022-01-10 14:36:16 +000047
48reuse-lint:
49 reuse --root . lint