Skip to content
Snippets Groups Projects

AssignmentCollection.__bool__

AssignmentCollection can be used in many cases where you could also use a List[Assignment]. With AssignmentCollection.__bool__, an empty AssignmentCollection is falsy and a non-empty one truthy.

So you can assert assignments, 'must not be emtpy'

Edited by Stephan Seitz

Merge request reports

Pipeline #20564 passed with warnings

Pipeline passed with warnings for fbf1ec12 on seitz:AssignmentCollection.__bool__

Merged by Martin BauerMartin Bauer Dec 17, 2019 (Dec 17, 2019 12:30pm UTC)

Loading

Pipeline #20566 passed

Pipeline passed for 00c00c45 on master

Test coverage 78.08% from 0 jobs

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading