Research portable Memory game | Исследовать портируемую игру Память
Вы не можете выбрать более 25 тем
Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
|
- from cli import *
- from cli_Context import *
- from memory import *
- from memory_Context import *
-
- def cli_test_greetUser(
- ) -> str:
- c = cli_createContext()
- c = cli_greetUser(c)
- if (
- c.recentField == "outputGreeting"
- ):
- return "OK: cli_greetUser"
- #}
- return "ERR: cli_greetUser"
- #}
-
- def cli_test_selectItem(
- ) -> str:
- c = cli_createContext()
- c.cMemory = memory_createContext()
- c.input = "1"
- c = cli_selectItem(c)
- if (
- c.recentField == "cMemory" and
- c.cMemory.recentField == "selectedItems"
- ):
- return "OK: cli_selectItem"
- #}
- return "ERR: cli_selectItem"
- #}
-
- def cli_test_shouldPromptSelection(
- ) -> str:
- c = cli_createContext()
- c.cMemory = memory_createContext()
- c.input = "1"
- c = cli_selectItem(c)
- c = cli_shouldPromptSelection(c)
- if (
- c.recentField == "outputPromptSelection"
- ):
- return "OK: cli_shouldPromptSelection"
- #}
- return "ERR: cli_shouldPromptSelection"
- #}
-
- def cli_test_shouldReportIvalidItemSelection_outOfBoundsMin(
- ) -> str:
- c = cli_createContext()
- c.cMemory = memory_createContext()
- c.input = "0"
- c = cli_selectItem(c)
- c = cli_shouldReportInvalidItemSelection(c)
- if (
- c.recentField == "outputInvalidItemSelection"
- ):
- return "OK: cli_shouldReportInvalidItemSelection"
- #}
- return "ERR: cli_shouldReportInvalidItemSelection"
- #}
-
- def cli_test_showHelp_h(
- ) -> str:
- c = cli_createContext()
- c.input = "h"
- c = cli_showHelp(c)
- if (
- c.recentField == "outputHelp"
- ):
- return "OK: cli_showHelp_h"
- #}
- return "ERR: cli_showHelp_h"
- #}
-
- def cli_test_showHelp_help(
- ) -> str:
- c = cli_createContext()
- c.input = "help"
- c = cli_showHelp(c)
- if (
- c.recentField == "outputHelp"
- ):
- return "OK: cli_showHelp_help"
- #}
- return "ERR: cli_showHelp_help"
- #}
|