()
| 197 | |
| 198 | |
| 199 | def test_required_match(): |
| 200 | assert Required(Option('-a')).match([Option('-a')]) == \ |
| 201 | (True, [], [Option('-a')]) |
| 202 | assert Required(Option('-a')).match([]) == (False, [], []) |
| 203 | assert Required(Option('-a')).match([Option('-x')]) == \ |
| 204 | (False, [Option('-x')], []) |
| 205 | assert Required(Option('-a'), Option('-b')).match([Option('-a')]) == \ |
| 206 | (False, [Option('-a')], []) |
| 207 | |
| 208 | |
| 209 | def test_either_match(): |