# TFS-ONCE deploy config for the p4-end-to-end test suite. Adapted from
# src/tests/ryu-openflow/deploy_specs.sh's own template and ordering, but
# TFS_COMPONENTS is computed dynamically as the UNION of every test's own
# (much simpler) deploy_specs.sh in the mininet-testing repo, rather than
# a human hand-toggling the commented blocks the reference file has.
#
# This is the ONE place that knows TFS's component dependency order
# (e.g. opticalcontroller/qkd_app must be inserted immediately before
# "service", not just appended) -- mininet-testing's own
# collect-tfs-components.sh deliberately does NOT reimplement this; it
# only computes the requested SET. Keeping the ordering logic here, once,
# is what stops the two repos' copies of "how TFS components depend on
# each other" from silently drifting apart.
#
# REQUESTED_COMPONENTS (space-separated) must already be exported before
# this file is sourced -- see .gitlab-ci.yml's deploy_tfs_once job, which
# runs mininet-testing/common/ci/collect-tfs-components.sh and exports
# its output as REQUESTED_COMPONENTS before sourcing this file.
: "${REQUESTED_COMPONENTS:?REQUESTED_COMPONENTS must be exported before sourcing this file (see collect-tfs-components.sh in mininet-testing MDG repo)}"
_has_component(){
# $1: component name to test for membership in REQUESTED_COMPONENTS