Skip to content

Commit 930122b

Browse files
committed
ci: lint fixes
1 parent 9f04560 commit 930122b

File tree

1 file changed

+18
-14
lines changed

1 file changed

+18
-14
lines changed

gitlab/tests/objects/test_projects.py

Lines changed: 18 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,10 @@ def resp_get_active_services(url, request):
258258

259259

260260
@urlmatch(
261-
scheme="http", netloc="localhost", path="/api/v4/projects/1/pipeline_schedules$", method="post",
261+
scheme="http",
262+
netloc="localhost",
263+
path="/api/v4/projects/1/pipeline_schedules$",
264+
method="post",
262265
)
263266
def resp_create_project_pipeline_schedule(url, request):
264267
"""Mock for creating project pipeline Schedules POST response."""
@@ -287,7 +290,10 @@ def resp_create_project_pipeline_schedule(url, request):
287290

288291

289292
@urlmatch(
290-
scheme="http", netloc="localhost", path="/api/v4/projects/1/pipeline_schedules/14/play", method="post",
293+
scheme="http",
294+
netloc="localhost",
295+
path="/api/v4/projects/1/pipeline_schedules/14/play",
296+
method="post",
291297
)
292298
def resp_play_project_pipeline_schedule(url, request):
293299
"""Mock for playing a project pipeline schedule POST response."""
@@ -522,22 +528,20 @@ def test_update_service(self):
522528

523529

524530
class TestProjectPipelineSchedule(TestProject):
525-
526-
@with_httmock(resp_create_project_pipeline_schedule,
527-
resp_play_project_pipeline_schedule)
531+
@with_httmock(
532+
resp_create_project_pipeline_schedule, resp_play_project_pipeline_schedule
533+
)
528534
def test_project_pipeline_schedule_play(self):
529-
description = 'Build packages'
530-
cronline = '0 1 * * 5'
531-
sched = self.project.pipelineschedules.create({
532-
'ref': 'master',
533-
'description': description,
534-
'cron': cronline})
535+
description = "Build packages"
536+
cronline = "0 1 * * 5"
537+
sched = self.project.pipelineschedules.create(
538+
{"ref": "master", "description": description, "cron": cronline}
539+
)
535540
self.assertIsNotNone(sched)
536541
self.assertEqual(description, sched.description)
537542
self.assertEqual(cronline, sched.cron)
538543

539544
play_result = sched.play()
540545
self.assertIsNotNone(play_result)
541-
self.assertIn('message', play_result)
542-
self.assertEqual('201 Created', play_result['message'])
543-
546+
self.assertIn("message", play_result)
547+
self.assertEqual("201 Created", play_result["message"])

0 commit comments

Comments
 (0)