Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ jobs:
test:
- cni-calico-deep
- deep
- deep-native-sidecar
- deep-non-native-sidecar
runs-on: ${{ vars.LINKERD2_RUNNER || 'ubuntu-24.04' }}
timeout-minutes: 15
steps:
Expand Down
8 changes: 4 additions & 4 deletions bin/_test-helpers.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ testdir=$bindir/../test/integration

##### Test setup helpers #####

export default_test_names=(deep deep-native-sidecar viz tracing external helm-upgrade uninstall upgrade-edge default-policy-deny rsa-ca)
export default_test_names=(deep deep-non-native-sidecar viz tracing external helm-upgrade uninstall upgrade-edge default-policy-deny rsa-ca)
export external_resource_test_names=(external-resources)
# TODO(alpeb): add test cni-calico-deep-dual-stack
export dual_stack_test_names=(deep-dual-stack)
Expand All @@ -25,7 +25,7 @@ tests_usage() {

Optionally specify a test with the --name flag: [${all_test_names[*]}]

Note: The cluster-domain, deep-native-sidecar cni-calico-deep and multicluster tests require a custom cluster configuration (see bin/_test-helpers.sh)
Note: The cluster-domain, deep-non-native-sidecar cni-calico-deep and multicluster tests require a custom cluster configuration (see bin/_test-helpers.sh)

Usage:
${progname} [--images docker|archive|skip] [--name test-name] [--skip-cluster-create] /path/to/linkerd
Expand Down Expand Up @@ -445,8 +445,8 @@ run_deep_test() {
run_test "$testdir/deep/..."
}

run_deep-native-sidecar_test() {
run_test "$testdir/deep/..." --native-sidecar
run_deep-non-native-sidecar_test() {
run_test "$testdir/deep/..." --non-native-sidecar
}

run_deep-dual-stack_test() {
Expand Down
4 changes: 2 additions & 2 deletions test/integration/deep/install_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ func TestInstall(t *testing.T) {
cmd = append(cmd, "--linkerd-cni-enabled")
}

if TestHelper.NativeSidecar() {
cmd = append(cmd, "--set", "proxy.nativeSidecar=true")
if TestHelper.NonNativeSidecar() {
cmd = append(cmd, "--set", "proxy.nativeSidecar=false")
}

if TestHelper.DualStack() {
Expand Down
4 changes: 2 additions & 2 deletions test/integration/viz/install_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,8 @@ func TestInstallVizHA(t *testing.T) {
"--ha",
}

if TestHelper.NativeSidecar() {
cmd = append(cmd, "--set", "proxy.nativeSidecar=true")
if TestHelper.NonNativeSidecar() {
cmd = append(cmd, "--set", "proxy.nativeSidecar=false")
}

out, err := TestHelper.LinkerdRun(cmd...)
Expand Down
12 changes: 6 additions & 6 deletions testutil/test_helper.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ type TestHelper struct {
cni bool
calico bool
dualStack bool
nativeSidecar bool
nonNativeSidecar bool
defaultInboundPolicy string
httpClient http.Client
KubernetesHelper
Expand Down Expand Up @@ -207,7 +207,7 @@ func NewTestHelper() *TestHelper {
cni := flag.Bool("cni", false, "whether to install linkerd with CNI enabled")
calico := flag.Bool("calico", false, "whether to install calico CNI plugin")
dualStack := flag.Bool("dual-stack", false, "whether to run the dual-stack tests")
nativeSidecar := flag.Bool("native-sidecar", false, "whether to install using native sidecar injection")
nonNativeSidecar := flag.Bool("non-native-sidecar", false, "whether to install using non-native sidecar injection")
defaultInboundPolicy := flag.String("default-inbound-policy", "", "if non-empty, passed to --set proxy.defaultInboundPolicy at linkerd's install time")
flag.Parse()

Expand Down Expand Up @@ -255,7 +255,7 @@ func NewTestHelper() *TestHelper {
cni: *cni,
calico: *calico,
dualStack: *dualStack,
nativeSidecar: *nativeSidecar,
nonNativeSidecar: *nonNativeSidecar,
uninstall: *uninstall,
defaultInboundPolicy: *defaultInboundPolicy,
}
Expand Down Expand Up @@ -409,9 +409,9 @@ func (h *TestHelper) DualStack() bool {
return h.dualStack
}

// NativeSidecar determines whether native sidecar injection is enabled
func (h *TestHelper) NativeSidecar() bool {
return h.nativeSidecar
// NativeSidecar determines whether non-native sidecar injection is enabled
func (h *TestHelper) NonNativeSidecar() bool {
return h.nonNativeSidecar
}

// AddInstalledExtension adds an extension name to installedExtensions to
Expand Down