From aba5b32fbbc1ed36e7b40f6ae4264a72abd6bf39 Mon Sep 17 00:00:00 2001 From: sebgoti Date: Thu, 27 May 2021 13:40:33 +0200 Subject: [PATCH] First & Second projects added --- 02_crowsnest/test.py | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/02_crowsnest/test.py b/02_crowsnest/test.py index d4e25c6c7..ce4c98ebf 100755 --- a/02_crowsnest/test.py +++ b/02_crowsnest/test.py @@ -9,9 +9,10 @@ 'brigantine', 'clipper', 'dreadnought', 'frigate', 'galleon', 'haddock', 'junk', 'ketch', 'longboat', 'mullet', 'narwhal', 'porpoise', 'quay', 'regatta', 'submarine', 'tanker', 'vessel', 'whale', 'xebec', 'yatch', - 'zebrafish' + 'zebrafish' ] -vowel_words = ['aviso', 'eel', 'iceberg', 'octopus', 'upbound'] +consonant_words_upper = ['Brigantine', 'Vessel'] +vowel_words = ['aviso', 'eel', 'iceberg', 'octopus', 'upbound', 'Octopus', 'Eel'] template = 'Ahoy, Captain, {} {} off the larboard bow!' @@ -66,3 +67,12 @@ def test_vowel_upper(): for word in vowel_words: out = getoutput(f'{prg} {word.upper()}') assert out.strip() == template.format('an', word.upper()) + + +# ------------------------------------------------- +def test_uper_incoming(): + """Octopus -> An Octopus""" + + for word in consonant_words_upper: + out = getoutput(f'{prg} {word}') + assert out.strip() == template.format('A', word)