aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/tui-golden.py59
1 files changed, 59 insertions, 0 deletions
diff --git a/scripts/tui-golden.py b/scripts/tui-golden.py
index b339f2d..4fee4df 100755
--- a/scripts/tui-golden.py
+++ b/scripts/tui-golden.py
@@ -60,6 +60,7 @@ KEYS = {
"ctrlenter-kitty": "\x1b[13;5u",
"f5": "\x1b[15~",
"f9": "\x1b[20~",
+ "f2": "\x1bOQ",
}
# {org_name} {org_nr} {fy_label} {fy_start} {fy_end} are substituted at run
@@ -258,6 +259,64 @@ SCENARIOS = [
"expect": ["Kunder", "Testkund AB"],
},
{
+ "name": "customer-draft",
+ "screen": "customers",
+ "expect": ["Kunder", "Testkund AB"],
+ "steps": [
+ {
+ "keys": ["ctrln"],
+ "expect": ["Ny kund", "<UTKAST>"],
+ },
+ {
+ "keys": ["enter", "Utkastkund", "enter"],
+ "expect": ["Ny kund", "<UTKAST>", "Utkastkund"],
+ },
+ {
+ "keys": ["esc"],
+ "expect": ["Kunder", "<UTKAST> Utkastkund"],
+ },
+ {
+ "keys": ["end", "up"],
+ "expect": ["<UTKAST> Utkastkund"],
+ },
+ {
+ "keys": ["f2"],
+ "expect": ["Åtgärder", "Öppna", "Radera utkast"],
+ },
+ {
+ "keys": ["down", "enter"],
+ "expect": ["Radera utkastet?"],
+ },
+ {
+ "keys": ["enter"],
+ "expect": ["Kunder", "Testkund AB"],
+ },
+ ],
+ },
+ {
+ "name": "customer-draft-save",
+ "screen": "customers",
+ "expect": ["Kunder", "Testkund AB"],
+ "steps": [
+ {
+ "keys": ["ctrln"],
+ "expect": ["Ny kund", "<UTKAST>"],
+ },
+ {
+ "keys": ["enter", "Sparad kund", "enter"],
+ "expect": ["Sparad kund", "<UTKAST>"],
+ },
+ {
+ "keys": ["f9"],
+ "expect": ["Sparat."],
+ },
+ {
+ "keys": ["enter"],
+ "expect": ["Kunder", "Sparad kund"],
+ },
+ ],
+ },
+ {
"name": "invoice-form",
"screen": "invoices",
"steps": [