Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # ---------- tasks/escher_tasks/task_7__keys_and_locks.py -------------
- def keys_and_locks(lock, some_key):
- return True
- # ---------- tests/test_escher_tasks/test_task_7__keys_and_locks.py -------------
- from tasks.escher_tasks.task_7__keys_and_locks import keys_and_locks
- def test_keys_and_locks():
- assert keys_and_locks('''
- 0##0
- 0##0
- 00#0
- 00##
- 00##''',
- '''
- 00000
- 000##
- #####
- ##000
- 00000''') == True
- assert keys_and_locks('''
- ###0
- 00#0''',
- '''
- 00000
- 00000
- #0000
- ###00
- 0#000
- 0#000''') == False
- assert keys_and_locks('''
- 0##0
- 0#00
- 0000''',
- '''
- ##000
- #0000
- 00000
- 00000
- 00000''') == True
- assert keys_and_locks('''
- ###0
- 0#00
- 0000''',
- '''
- ##00
- ##00''') == False
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement