Commit Graph

343 Commits

Author SHA1 Message Date
karmada-bot b5b065da8a
Merge pull request #5332 from a7i/work-suspend-event
work suspension: emit event for work dispatch status
2024-08-12 13:57:31 +08:00
karmada-bot f5f53c33c8
Merge pull request #5141 from liangyuanpeng/fix_test_k8s1.30
Fix test for corev1.LoadBalancerIngress,add IP model to VIP when ip is setting.
2024-08-12 11:23:32 +08:00
Lan Liang c9ccf9a849 Fix test for corev1.LoadBalancerIngress,add IP model to VIP when ip is setting.
Signed-off-by: Lan Liang <gcslyp@gmail.com>
2024-08-09 10:23:06 +00:00
Amir Alavi 8f707f35b4
work suspension: emit event for work dispatch status
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>

fix lint

fix lint
2024-08-09 06:15:05 -04:00
Mohamed Awnallah f59ea2dea6 test/e2e: unfiy random string length generation
In this commit, we unify the generation of random string
length by utilizing `RandomStrLength` global constant.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-08-09 07:56:59 +00:00
karmada-bot 052b06ecc2
Merge pull request #5333 from a7i/duplicate-import
chore: remove duplicate imports
2024-08-09 14:52:29 +08:00
Amir Alavi 010d38954e
chore: remove duplicate imports
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2024-08-08 23:22:37 -04:00
Amir Alavi 1d8e0a029e
work suspension: work status conditions
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2024-08-07 22:25:05 -04:00
xovoxy 38ee277de7 optimize: used unified context in controller
Signed-off-by: xovoxy <xilovele@gmail.com>
2024-08-06 11:44:20 +08:00
karmada-bot 920baceafd
Merge pull request #4838 from a7i/work-suspend
feat: cluster-level resource propagation pause and resume capabilities
2024-08-06 09:38:27 +08:00
karmada-bot 8b4e006f03
Merge pull request #5244 from mohamedawnallah/testKarmadactlTaintCommand
test/e2e/karmadactl_test.go: test taint command
2024-08-05 17:23:26 +08:00
Mohamed Awnallah 37af811de6 test/e2e/karmadactl_test.go: test taint command
In this commit, we add e2e tests for the `karmadactl taint`
command to ensure it handles various scenarios correctly.
The tests include:

- Applying taints with different effects (NoSchedule, NoExecute) to a cluster.
- Reapplying taints without the `--overwrite` flag to ensure an error is returned.
- Overwriting existing taints using the `--overwrite` flag.
- Removing taints from a cluster.
- Running the taint command in `--dry-run` mode to ensure no actual changes are made.
- Verifying that taints were not applied during `--dry-run` mode.
- Ensuring the command returns an error for an invalid flag.
- Ensuring the command returns an error when attempting to taint a non-existent cluster.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
Co-authored-by: zhzhuang-zju <m17799853869@163.com>
2024-08-05 03:48:17 +00:00
zhzhuang-zju 978ea81937 cleanup: Remove redundant e2e testing steps
Signed-off-by: zhzhuang-zju <m17799853869@163.com>
2024-08-03 11:17:11 +08:00
whitewindmills 575931523c Fix incorrect error code judgment in e2e tests
Signed-off-by: whitewindmills <jayfantasyhjh@gmail.com>
2024-07-30 17:05:10 +08:00
Amir Alavi 58dbd6b56e
feat: cluster-level resource propagation pause and resume capabilities
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2024-07-29 19:03:52 -04:00
karmada-bot 8a86cd02af
Merge pull request #5263 from chaosi-zju/e2e-2
print all binding and related objects to log file after each e2e failure case
2024-07-29 17:12:20 +08:00
chaosi-zju 081681b27d print all binding and related objects to log file after each failure e2e case
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-07-29 15:34:59 +08:00
zhzhuang-zju 903648a9de fix unexpected interference between different e2e use cases
Signed-off-by: zhzhuang-zju <m17799853869@163.com>
2024-07-27 17:08:11 +08:00
karmada-bot 195c371fea
Merge pull request #5261 from a7i/e2e-clusterresourcebinding-annotation
e2e: clusterresourcebinding permanent-id label
2024-07-27 15:43:18 +08:00
chaosi-zju 459864d3b1 fix unexpected interference between different e2e use cases
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-07-27 09:30:47 +08:00
Amir Alavi b1ce2f1cdc
e2e: clusterresourcebinding permanent-id label
Signed-off-by: Amir Alavi <amiralavi7@gmail.com>
2024-07-26 19:05:32 -04:00
karmada-bot c5d182b908
Merge pull request #5239 from mohamedawnallah/unifyAccessToClusterMembersinE2E
test: unify access to cluster members utilizing `framework.ClusterMembers()` as input parameter
2024-07-24 10:20:16 +08:00
karmada-bot 39e8587649
Merge pull request #4575 from zhzhuang-zju/cpp
complete the e2e test case scenarios for clusterpp
2024-07-24 10:08:15 +08:00
Mohamed Awnallah f71bc13963 test: unify access to cluster members
In this commit, we unify access to cluster members
in `test/helper/NewFederatedResourceQuota()` by passing
`clusterNames` as an input parameter. This commit is also
a follow-up of this PR #5226.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-23 17:46:54 +00:00
zhzhuang-zju d43a119c0a complete the e2e test case scenarios for clusterpp
Signed-off-by: zhzhuang-zju <m17799853869@163.com>
2024-07-23 16:11:09 +08:00
Mohamed Awnallah cb43384155 test/e2e/karmadactl_test.go: test options command
In this commit, we test `karmadactl options` on listing
all available global options successfully and returning
an error for invalid flag in options.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-19 09:02:56 +00:00
karmada-bot 5e3e5ad513
Merge pull request #5210 from mohamedawnallah/testKarmadactlTokenCommand
test/e2e/karmadactl_test.go: test token command
2024-07-19 16:33:11 +08:00
Mohamed Awnallah 9c65d4e142 test/e2e/karmadactl_test.go: test token command
In this commit, we add tests for the `karmadactl token`
command. These include creating, deleting, listing, and
validating bootstrap tokens. We test scenarios such as
successful token creation and deletion, error handling
for invalid flag, and ensuring the correct format for
tokens. The utility functions `extractTokenIDAndSecret`
and `validateTokenFormat` are used to validate token
format and extract token components.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
Co-authored-by: zhzhuang-zju <m17799853869@163.com>
2024-07-19 07:41:15 +00:00
Mohamed Awnallah 2a55c98b91 test/e2e: unify access to cluster members
Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-19 03:56:15 +00:00
Mohamed Awnallah ad1e76bac2
test/e2e/karmadactl_test.go: test describe command
In this commit, we test `karmadactl describe` command
on existing resource, non-existing resource, non-existing
namespace, and invalid resource type.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-17 10:59:02 +03:00
Mohamed Awnallah d2a47dde53
test/e2e/karmadactl_test.go: test get command
In this commit, we test `karmadactl get` command
on existing resource, non-existing resource, and
invalid resource type.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-17 09:44:31 +03:00
Mohamed Awnallah 1fc977e38c
test/e2e/karmadactl_test.go: test version command
In this commit, we test `karmadactl version` command to
make sure it return valid information and return error
when invalid flag is provided.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-17 06:40:45 +03:00
Mohamed Awnallah 09ec78933d test/e2e/karmadactl_test.go: test logs command
In this commit, we test `karmadactl logs` command
on existing cluster, existing pod, non-existing pod,
non-existing cluster, and invalid input.

Signed-off-by: Mohamed Awnallah <mohamedmohey2352@gmail.com>
2024-07-15 10:32:42 +00:00
whitewindmills 2450bd6041 Correct licenses format
Signed-off-by: whitewindmills <jayfantasyhjh@gmail.com>
2024-07-04 10:35:16 +08:00
changzhen fecd9a74a9 fix update cluster conflict error in the remedy e2e test
Signed-off-by: changzhen <changzhen5@huawei.com>
2024-06-27 19:48:01 +08:00
karmada-bot 86d1ac7aaa
Merge pull request #5033 from Affan-7/e2e-test
Add combined case 3 in the lazy activation policy tests
2024-06-14 11:51:41 +08:00
Mohammed Affan 8f1b112e89 Add combined case 3 in the lazy activation policy tests
Signed-off-by: Mohammed Affan <mohammed.affan.727@gmail.com>
2024-06-13 09:01:27 +05:30
whitewindmills 58c15c8ed9 fix code inspection errors
Signed-off-by: whitewindmills <jayfantasyhjh@gmail.com>
2024-06-12 17:55:59 +08:00
changzhen d5a317a165 fix-remedy-e2e-errors
Signed-off-by: changzhen <changzhen5@huawei.com>
2024-06-12 15:22:01 +08:00
changzhen 87a1938643 add e2e for remedy
Signed-off-by: changzhen <changzhen5@huawei.com>
2024-05-31 16:56:57 +08:00
changzhen 26abce8b6a add e2e for remedy
Signed-off-by: changzhen <changzhen5@huawei.com>
2024-05-31 15:46:33 +08:00
Lan Liang ed0f26c328 cleanup pointer, use ptr.Toto obtain a pointer, ptr.Deref to dereference a pointer.
The new k8s.io/utils/ptr package provides generic wrapper functions,
which can be used instead of type-specific pointer wrapper functions.
This replaces the latter with the former, and migrates other uses of
the deprecated pointer package to ptr in affacted files.

See kubernetes/utils#283 for details.

Signed-off-by: Lan Liang <gcslyp@gmail.com>
2024-05-28 05:32:33 +00:00
chaosi-zju a8b4050ee7 support auto delete WorkloadRebalancer when time up.
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-05-27 09:56:06 +08:00
chaosi-zju 761bbf031d add more e2e for WorkloadRebalancer
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-05-22 16:52:11 +08:00
karmada-bot e4a4a474f4
Merge pull request #3906 from Affan-7/cleanup-wait.poll
Migrate deprecated wait.Poll function
2024-05-22 15:52:18 +08:00
Lan Liang 5a4539d404 migrate wait.PollImmediate to wait.PollUntilContextTimeout.
Signed-off-by: Lan Liang <gcslyp@gmail.com>
2024-05-22 05:51:49 +00:00
Mohammed Affan 6a07cca040 Migrate deprecated wait.poll
Signed-off-by: Mohammed Affan <mohammed.affan.727@gmail.com>
2024-05-22 11:19:51 +08:00
chaosi-zju 57951d5bd6 fix e2e unstable failure caused by taint cluster
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-05-20 17:23:29 +08:00
chaosi-zju 9211d27973 add e2e for WorkloadRebalancer
Signed-off-by: chaosi-zju <chaosi@zju.edu.cn>
2024-05-16 16:18:30 +08:00
karmada-bot 6cfed59332
Merge pull request #4930 from zhzhuang-zju/golangciwith1.58.0
Bump golangci-lint to v1.58.0
2024-05-15 17:20:19 +08:00