MCPcopy Create free account
hub / github.com/commitizen-tools/commitizen / test_questions

Function test_questions

tests/test_cz_customize.py:519–539  ·  view source on GitHub ↗
(config)

Source from the content-addressed store, hash-verified

517
518
519def test_questions(config):
520 cz = CustomizeCommitsCz(config)
521 questions = cz.questions()
522 expected_questions = [
523 {
524 "type": "list",
525 "name": "change_type",
526 "choices": [
527 {"value": "feature", "name": "feature: A new feature."},
528 {"value": "bug fix", "name": "bug fix: A bug fix."},
529 ],
530 "message": "Select the type of change you are committing",
531 },
532 {"type": "input", "name": "message", "message": "Body."},
533 {
534 "type": "confirm",
535 "name": "show_message",
536 "message": "Do you want to add body message in commit?",
537 },
538 ]
539 assert list(questions) == expected_questions
540
541
542def test_questions_unicode(config_with_unicode):

Callers

nothing calls this directly

Calls 2

questionsMethod · 0.95
CustomizeCommitsCzClass · 0.90

Tested by

no test coverage detected