2018-09-19 11:49:43 +02:00
|
|
|
*** Settings ***
|
|
|
|
Documentation Harbor BATs
|
|
|
|
Resource ../../resources/APITest-Util.robot
|
|
|
|
Resource ../../resources/Docker-Util.robot
|
|
|
|
Library ../../apitests/python/library/Harbor.py ${SERVER_CONFIG}
|
|
|
|
Library OperatingSystem
|
|
|
|
Library String
|
|
|
|
Library Collections
|
|
|
|
Library requests
|
|
|
|
Library Process
|
|
|
|
Default Tags APIDB
|
|
|
|
|
|
|
|
*** Variables ***
|
|
|
|
${SERVER} ${ip}
|
|
|
|
${SERVER_URL} https://${SERVER}
|
|
|
|
${SERVER_API_ENDPOINT} ${SERVER_URL}/api
|
|
|
|
&{SERVER_CONFIG} endpoint=${SERVER_API_ENDPOINT} verify_ssl=False
|
|
|
|
|
|
|
|
*** Test Cases ***
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-11 04:19:29 +01:00
|
|
|
Test Case - Garbage Collection
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] gc
|
2020-03-11 04:19:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_garbage_collection.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2018-10-31 06:13:31 +01:00
|
|
|
Test Case - Add Private Project Member and Check User Can See It
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] private_member
|
2018-11-01 11:26:04 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_add_member_to_private_project.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-21 10:08:27 +01:00
|
|
|
Test Case - Delete a Repository of a Certain Project Created by Normal User
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] del_repo
|
2020-02-21 10:08:27 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_del_repo.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Add a System Global Label to a Certain Tag
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] global_lbl
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_add_sys_label_to_tag.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-02 06:04:13 +01:00
|
|
|
Test Case - Add Replication Rule
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] replic_rule
|
2020-02-02 06:04:13 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_add_replication_rule.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2018-11-14 09:23:44 +01:00
|
|
|
Test Case - Edit Project Creation
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] pro_creation
|
2018-11-14 09:23:44 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_edit_project_creation.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Manage Project Member
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] member
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_manage_project_member.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Project Level Policy Content Trust
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] content_trust
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_project_level_policy_content_trust.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-19 07:56:37 +01:00
|
|
|
Test Case - User View Logs
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] view_logs
|
2020-03-19 07:56:37 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_user_view_logs.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-11 08:00:52 +01:00
|
|
|
Test Case - List Helm Charts
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] list_helm_charts
|
2020-03-11 08:00:52 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_list_helm_charts.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Assign Sys Admin
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] assign_adin
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_assign_sys_admin.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-21 10:08:27 +01:00
|
|
|
Test Case - Copy Artifact Outside Project
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] copy_artifact
|
2020-02-21 10:08:27 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_copy_artifact_outside_project.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Robot Account
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] robot_account
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_robot_account.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Sign A Image
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] sign_image
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_sign_image.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-12 04:50:30 +01:00
|
|
|
Test Case - Project Quota
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] quota
|
|
|
|
Harbor API Test ./tests/apitests/python/test_project_quota.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-06-22 04:34:03 +02:00
|
|
|
Test Case - System Level CVE Allowlist
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] sys_cve
|
2020-06-22 04:34:03 +02:00
|
|
|
Harbor API Test ./tests/apitests/python/test_sys_cve_allowlists.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-06-22 04:34:03 +02:00
|
|
|
Test Case - Project Level CVE Allowlist
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] pro_cve
|
2020-06-22 04:34:03 +02:00
|
|
|
Harbor API Test ./tests/apitests/python/test_project_level_cve_allowlist.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Tag Retention
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] tag_retention
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_retention.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-02-25 03:40:29 +01:00
|
|
|
Test Case - Health Check
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] health
|
2020-02-25 03:40:29 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_health_check.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-01 10:57:40 +01:00
|
|
|
Test Case - Push Index By Docker Manifest
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] push_index
|
2020-03-01 10:57:40 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_push_index_by_docker_manifest.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-16 03:13:28 +01:00
|
|
|
Test Case - Push Chart By Helm3 Chart CLI
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] push_chart
|
2020-03-04 09:08:03 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_push_chart_by_helm3_chart_cli.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-07 04:15:19 +01:00
|
|
|
Test Case - Push Cnab Bundle
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] push_cnab
|
2020-03-07 04:15:19 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_push_cnab_bundle.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-16 08:46:43 +01:00
|
|
|
Test Case - Create/Delete tag
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] tag_cuid
|
2020-03-16 08:46:43 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_create_delete_tag.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-26 10:07:58 +01:00
|
|
|
Test Case - Scan Image
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] scan
|
2020-03-26 10:07:58 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_scan_image_artifact.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-03-26 10:07:58 +01:00
|
|
|
Test Case - Scan All Images
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] scan_all
|
2020-03-26 10:07:58 +01:00
|
|
|
Harbor API Test ./tests/apitests/python/test_system_level_scan_all.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-04-07 11:28:09 +02:00
|
|
|
Test Case - Registry API
|
2020-04-20 11:16:02 +02:00
|
|
|
[Tags] reg_api
|
2020-04-07 11:28:09 +02:00
|
|
|
Harbor API Test ./tests/apitests/python/test_registry_api.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-04-22 10:44:10 +02:00
|
|
|
Test Case - Push Image With Special Name
|
|
|
|
[Tags] special_repo_name
|
|
|
|
Harbor API Test ./tests/apitests/python/test_push_image_with_special_name.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-06-04 12:17:26 +02:00
|
|
|
Test Case - Push Artifact With ORAS CLI
|
|
|
|
[Tags] oras
|
2020-06-09 09:33:18 +02:00
|
|
|
Harbor API Test ./tests/apitests/python/test_push_files_by_oras.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-06-09 09:33:18 +02:00
|
|
|
Test Case - Push Singularity file With Singularity CLI
|
|
|
|
[Tags] singularity
|
|
|
|
Harbor API Test ./tests/apitests/python/test_push_sif_by_singularity.py
|
2020-06-16 11:34:30 +02:00
|
|
|
|
2020-06-15 08:20:23 +02:00
|
|
|
Test Case - Push Chart File To Chart Repository By Helm V2 With Robot Account
|
|
|
|
[Tags] helm2
|
|
|
|
Harbor API Test ./tests/apitests/python/test_push_chart_by_helm2_helm3_with_robot_Account.py
|
2020-06-30 09:56:35 +02:00
|
|
|
|
|
|
|
Test Case - Replication From Dockerhub
|
|
|
|
[Tags] replic_dockerhub
|
|
|
|
Harbor API Test ./tests/apitests/python/test_replication_from_dockerhub.py
|