Skip to content
Merged
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
8 changes: 4 additions & 4 deletions docs/demos/ArgoCD/fleet-argocd-integration.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ spec:
source:
path: docs/demos/ArgoCD/manifests/guestbook
repoURL: https://github.com/Azure/fleet.git
targetRevision: master
targetRevision: main
syncPolicy:
automated:
prune: true
Expand Down Expand Up @@ -548,7 +548,7 @@ guestbook guestbook-app Synced Healthy
kubectl get cm -n guestbook test-config -o yaml
apiVersion: v1
data:
branch: master
branch: main
cluster: member1 # <- member1 exclusive
kind: ConfigMap
metadata:
Expand All @@ -565,7 +565,7 @@ guestbook guestbook-app Synced Healthy
kubectl get cm -n guestbook test-config -o yaml
apiVersion: v1
data:
branch: master
branch: main
cluster: member2 # <- member2 exclusive
kind: ConfigMap
metadata:
Expand All @@ -582,7 +582,7 @@ guestbook guestbook-app Synced Healthy
kubectl get cm -n guestbook test-config -o yaml
apiVersion: v1
data:
branch: master
branch: main
cluster: member3 # <- member3 exclusive
kind: ConfigMap
metadata:
Expand Down
2 changes: 1 addition & 1 deletion docs/demos/ArgoCD/manifests/guestbook-app.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ spec:
source:
path: docs/demos/ArgoCD/manifests/guestbook # manifest path
repoURL: https://github.com/Azure/fleet.git # source repo
targetRevision: argocd-demo # source branch
targetRevision: main # source branch
syncPolicy:
automated:
prune: true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ kind: ConfigMap
metadata:
name: test-config
data:
branch: master
branch: main
cluster: member1
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ kind: ConfigMap
metadata:
name: test-config
data:
branch: master
branch: main
cluster: member2
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ kind: ConfigMap
metadata:
name: test-config
data:
branch: master
branch: main
cluster: member3
11 changes: 4 additions & 7 deletions test/e2e/enveloped_object_placement_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -342,7 +342,7 @@ var _ = Describe("Process objects with generate name", Ordered, func() {
// Create the namespace with both name and generate name set.
ns := appNamespace()
ns.GenerateName = nsGenerateName
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

// Create an envelope config map.
cm := &corev1.ConfigMap{
Expand Down Expand Up @@ -481,11 +481,8 @@ var _ = Describe("Process objects with generate name", Ordered, func() {
})

AfterAll(func() {
// Remove the CRP.
cleanupCRP(crpName)

// Clean the placed resources.
cleanWorkResourcesOnCluster(allMemberClusters[0])
By(fmt.Sprintf("deleting placement %s and related resources", crpName))
ensureCRPAndRelatedResourcesDeleted(crpName, allMemberClusters)
Comment thread
zhiying-lin marked this conversation as resolved.
})
})

Expand Down Expand Up @@ -638,7 +635,7 @@ func readEnvelopTestManifests() {
// createWrappedResourcesForEnvelopTest creates some enveloped resources on the hub cluster for testing purposes.
func createWrappedResourcesForEnvelopTest() {
ns := appNamespace()
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)
// modify the configMap according to the namespace
testConfigMap.Namespace = ns.Name
Expect(hubClient.Create(ctx, &testConfigMap)).To(Succeed(), "Failed to create config map %s", testConfigMap.Name)
Expand Down
4 changes: 2 additions & 2 deletions test/e2e/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -668,7 +668,7 @@ func createWorkResource(name, namespace string) {
// createWorkResources creates some resources on the hub cluster for testing purposes.
func createWorkResources() {
ns := appNamespace()
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

configMap := appConfigMap()
Expect(hubClient.Create(ctx, &configMap)).To(Succeed(), "Failed to create config map %s", configMap.Name)
Expand All @@ -681,7 +681,7 @@ func cleanupWorkResources() {

func cleanWorkResourcesOnCluster(cluster *framework.Cluster) {
ns := appNamespace()
Expect(client.IgnoreNotFound(cluster.KubeClient.Delete(ctx, &ns))).To(Succeed(), "Failed to delete namespace %s", ns.Namespace)
Expect(client.IgnoreNotFound(cluster.KubeClient.Delete(ctx, &ns))).To(Succeed(), "Failed to delete namespace %s", ns.Name)

workResourcesRemovedActual := workNamespaceRemovedFromClusterActual(cluster)
Eventually(workResourcesRemovedActual, workloadEventuallyDuration, eventuallyInterval).Should(Succeed(), "Failed to remove work resources from %s cluster", cluster.ClusterName)
Expand Down
10 changes: 5 additions & 5 deletions test/upgrade/before/scenarios_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ var _ = Describe("CRP with non-trackable resources, all available (before upgrad
BeforeAll(func() {
// Create the resources.
ns := appNamespace(workNamespaceName, crpName)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

// Job is currently untrackable in Fleet.
job := batchv1.Job{
Expand Down Expand Up @@ -159,7 +159,7 @@ var _ = Describe("CRP with availability failure (before upgrade)", Ordered, func
BeforeAll(func() {
// Create the resources.
ns := appNamespace(workNamespaceName, crpName)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

// Use a Service of the LoadBalancer type as by default KinD environment does not support
// this service type and such services will always be unavailable.
Expand Down Expand Up @@ -266,7 +266,7 @@ var _ = Describe("CRP with apply op failure (before upgrade)", Ordered, func() {

// Create the resources on the member cluster with a custom manager
ns := appNamespace(workNamespaceName, crpName)
Expect(memberCluster1EastProdClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(memberCluster1EastProdClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

configMap := appConfigMap(workNamespaceName, appConfigMapName)
configMap.Data = map[string]string{
Expand Down Expand Up @@ -368,7 +368,7 @@ var _ = Describe("CRP stuck in the rollout process (blocked by availability fail
BeforeAll(func() {
// Create the resources.
ns := appNamespace(workNamespaceName, crpName)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

// Use a Service of the ClusterIP type. KinD supports it and it will become available
// once an IP has been assigned.
Expand Down Expand Up @@ -697,7 +697,7 @@ var _ = Describe("CRP stuck in the rollout process (long wait time)", Ordered, f
BeforeAll(func() {
// Create the resources.
ns := appNamespace(workNamespaceName, crpName)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

// Job is currently untrackable in Fleet.
originalJob = &batchv1.Job{
Expand Down
2 changes: 1 addition & 1 deletion test/upgrade/before/utils_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ func checkIfAllMemberClustersHaveJoined() {
// createWorkResources creates some resources on the hub cluster for testing purposes.
func createWorkResources(workNamespaceName, appConfigMapName, crpName string) {
ns := appNamespace(workNamespaceName, crpName)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Namespace)
Expect(hubClient.Create(ctx, &ns)).To(Succeed(), "Failed to create namespace %s", ns.Name)

configMap := appConfigMap(workNamespaceName, appConfigMapName)
Expect(hubClient.Create(ctx, &configMap)).To(Succeed(), "Failed to create config map %s", configMap.Name)
Expand Down
Loading