Skip to content

Commit

Permalink
apply suggestions
Browse files Browse the repository at this point in the history
  • Loading branch information
rgildein committed Aug 22, 2024
1 parent 6a48a43 commit d6c9e0c
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion charms/istio-pilot/src/charm.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ def _istioctl_extra_flags(self):
"--set",
f"values.cni.cniConfDir={self.model.config['cni-conf-dir']}",
"--set",
"values.sidecarInjectorWebhook.injectedAnnotations.traffic\\.sidecar\\.istio\\.io/excludeOutboundIPRanges=0.0.0.0/0", # noqa
"values.sidecarInjectorWebhook.injectedAnnotations.traffic\.sidecar\.istio\.io/excludeOutboundIPRanges=0.0.0.0/0", # noqa
]
)
return extra_flags
Expand Down
6 changes: 4 additions & 2 deletions tests/test_bundle.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,9 @@ async def test_enable_ingress_auth(ops_test: OpsTest):
await ops_test.model.integrate(f"{ISTIO_PILOT}:ingress", f"{DEX_AUTH}:ingress")
await ops_test.model.integrate(f"{ISTIO_PILOT}:ingress", f"{OIDC_GATEKEEPER}:ingress")
await ops_test.model.integrate(f"{OIDC_GATEKEEPER}:oidc-client", f"{DEX_AUTH}:oidc-client")
await ops_test.model.integrate(f"{OIDC_GATEKEEPER}:dex-oidc-config", f"{DEX_AUTH}:dex-oidc-config")
await ops_test.model.integrate(
f"{OIDC_GATEKEEPER}:dex-oidc-config", f"{DEX_AUTH}:dex-oidc-config"
)
await ops_test.model.integrate(
f"{ISTIO_PILOT}:ingress-auth", f"{OIDC_GATEKEEPER}:ingress-auth"
)
Expand All @@ -275,7 +277,7 @@ async def test_enable_ingress_auth(ops_test: OpsTest):
await ops_test.model.wait_for_idle(
status="active",
raise_on_blocked=False,
timeout=60 * 20,
timeout=60 * 15,
)

# Wait for the pods from our secondary workload, just in case. This should be faster than
Expand Down
1 change: 0 additions & 1 deletion tests/test_bundle_tls_provider.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ def lightkube_client() -> lightkube.Client:


@pytest.mark.abort_on_fail
@pytest.mark.skip_if_deployed
async def test_build_and_deploy_istio_charms(ops_test: OpsTest):
"""Build and deploy istio-operators with TLS configuration."""
charms_path = "./charms/istio"
Expand Down
1 change: 0 additions & 1 deletion tests/test_bundle_tls_secret.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ def lightkube_client() -> lightkube.Client:


@pytest.mark.abort_on_fail
@pytest.mark.skip_if_deployed
async def test_build_and_deploy_istio_charms(ops_test: OpsTest):
"""Build and deploy istio-operators with TLS configuration."""
charms_path = "./charms/istio"
Expand Down
7 changes: 4 additions & 3 deletions tests/test_cos_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,9 +86,10 @@ async def test_metrics_enpoint(charm, metrics_path, metrics_port, ops_test):
await assert_metrics_endpoint(app, metrics_port=metrics_port, metrics_path=metrics_path)


@pytest.mark.parametrize("charm, path_to_alert_rules", [
(ISTIO_PILOT, ISTIO_PILOT_ALER_RULES), (ISTIO_GATEWAY_APP_NAME, ISTIO_GATEWAY_ALER_RULES)
])
@pytest.mark.parametrize(
"charm, path_to_alert_rules",
[(ISTIO_PILOT, ISTIO_PILOT_ALER_RULES), (ISTIO_GATEWAY_APP_NAME, ISTIO_GATEWAY_ALER_RULES)],
)
async def test_alert_rules(charm, path_to_alert_rules, ops_test):
"""Test check charm alert rules and rules defined in relation data bag."""
app = ops_test.model.applications[charm]
Expand Down

0 comments on commit d6c9e0c

Please sign in to comment.