Loading docs/cli-examples.rst +6 −1 Original line number Diff line number Diff line Loading @@ -9,6 +9,8 @@ CLI examples CI Lint ------- **ci-lint has been Removed in Gitlab 16, use project-ci-lint instead** Lint a CI YAML configuration from a string: .. note:: Loading Loading @@ -39,6 +41,9 @@ Validate a CI YAML configuration from a file (lints and exits with non-zero on f $ gitlab ci-lint validate --content @.gitlab-ci.yml Project CI Lint --------------- Lint a project's CI YAML configuration: .. code-block:: console Loading tests/functional/api/test_deploy_tokens.py +6 −2 Original line number Diff line number Diff line from datetime import date def test_project_deploy_tokens(gl, project): today = date.today().isoformat() deploy_token = project.deploytokens.create( { "name": "foo", "username": "bar", "expires_at": "2022-01-01", "expires_at": today, "scopes": ["read_registry"], } ) Loading @@ -12,7 +16,7 @@ def test_project_deploy_tokens(gl, project): deploy_token = project.deploytokens.get(deploy_token.id) assert deploy_token.name == "foo" assert deploy_token.expires_at == "2022-01-01T00:00:00.000Z" assert deploy_token.expires_at == today + "T00:00:00.000Z" assert deploy_token.scopes == ["read_registry"] assert deploy_token.username == "bar" Loading tests/functional/api/test_groups.py +2 −2 Original line number Diff line number Diff line Loading @@ -10,7 +10,7 @@ def test_groups(gl): "email": "user@test.com", "username": "user", "name": "user", "password": "user_pass", "password": "E4596f8be406Bc3a14a4ccdb1df80587", } ) user2 = gl.users.create( Loading @@ -18,7 +18,7 @@ def test_groups(gl): "email": "user2@test.com", "username": "user2", "name": "user2", "password": "user2_pass", "password": "E4596f8be406Bc3a14a4ccdb1df80587$2", } ) group1 = gl.groups.create( Loading tests/functional/api/test_merge_requests.py +2 −2 Original line number Diff line number Diff line Loading @@ -16,7 +16,7 @@ def test_merge_requests(project): } ) source_branch = "branch1" source_branch = "branch-merge-request-api" project.branches.create({"branch": source_branch, "ref": "main"}) project.files.create( Loading @@ -28,7 +28,7 @@ def test_merge_requests(project): } ) project.mergerequests.create( {"source_branch": "branch1", "target_branch": "main", "title": "MR readme2"} {"source_branch": source_branch, "target_branch": "main", "title": "MR readme2"} ) Loading tests/functional/api/test_users.py +1 −1 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ def test_create_user(gl, fixture_dir): "email": "foo@bar.com", "username": "foo", "name": "foo", "password": "foo_password", "password": "E4596f8be406Bc3a14a4ccdb1df80587$3", "avatar": open(fixture_dir / "avatar.png", "rb"), } ) Loading Loading
docs/cli-examples.rst +6 −1 Original line number Diff line number Diff line Loading @@ -9,6 +9,8 @@ CLI examples CI Lint ------- **ci-lint has been Removed in Gitlab 16, use project-ci-lint instead** Lint a CI YAML configuration from a string: .. note:: Loading Loading @@ -39,6 +41,9 @@ Validate a CI YAML configuration from a file (lints and exits with non-zero on f $ gitlab ci-lint validate --content @.gitlab-ci.yml Project CI Lint --------------- Lint a project's CI YAML configuration: .. code-block:: console Loading
tests/functional/api/test_deploy_tokens.py +6 −2 Original line number Diff line number Diff line from datetime import date def test_project_deploy_tokens(gl, project): today = date.today().isoformat() deploy_token = project.deploytokens.create( { "name": "foo", "username": "bar", "expires_at": "2022-01-01", "expires_at": today, "scopes": ["read_registry"], } ) Loading @@ -12,7 +16,7 @@ def test_project_deploy_tokens(gl, project): deploy_token = project.deploytokens.get(deploy_token.id) assert deploy_token.name == "foo" assert deploy_token.expires_at == "2022-01-01T00:00:00.000Z" assert deploy_token.expires_at == today + "T00:00:00.000Z" assert deploy_token.scopes == ["read_registry"] assert deploy_token.username == "bar" Loading
tests/functional/api/test_groups.py +2 −2 Original line number Diff line number Diff line Loading @@ -10,7 +10,7 @@ def test_groups(gl): "email": "user@test.com", "username": "user", "name": "user", "password": "user_pass", "password": "E4596f8be406Bc3a14a4ccdb1df80587", } ) user2 = gl.users.create( Loading @@ -18,7 +18,7 @@ def test_groups(gl): "email": "user2@test.com", "username": "user2", "name": "user2", "password": "user2_pass", "password": "E4596f8be406Bc3a14a4ccdb1df80587$2", } ) group1 = gl.groups.create( Loading
tests/functional/api/test_merge_requests.py +2 −2 Original line number Diff line number Diff line Loading @@ -16,7 +16,7 @@ def test_merge_requests(project): } ) source_branch = "branch1" source_branch = "branch-merge-request-api" project.branches.create({"branch": source_branch, "ref": "main"}) project.files.create( Loading @@ -28,7 +28,7 @@ def test_merge_requests(project): } ) project.mergerequests.create( {"source_branch": "branch1", "target_branch": "main", "title": "MR readme2"} {"source_branch": source_branch, "target_branch": "main", "title": "MR readme2"} ) Loading
tests/functional/api/test_users.py +1 −1 Original line number Diff line number Diff line Loading @@ -13,7 +13,7 @@ def test_create_user(gl, fixture_dir): "email": "foo@bar.com", "username": "foo", "name": "foo", "password": "foo_password", "password": "E4596f8be406Bc3a14a4ccdb1df80587$3", "avatar": open(fixture_dir / "avatar.png", "rb"), } ) Loading