Skip to content

Commit

Permalink
screenshot generator: dedicated section for errors; added generic Err…
Browse files Browse the repository at this point in the history
…orView
  • Loading branch information
kdmukai committed Aug 28, 2023
1 parent df9df46 commit 0883c8e
Showing 1 changed file with 14 additions and 8 deletions.
22 changes: 14 additions & 8 deletions tests/screenshot_generator/generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
from seedsigner.models.settings_definition import SettingsConstants, SettingsDefinition
from seedsigner.views import (MainMenuView, PowerOptionsView, RestartView, NotYetImplementedView, UnhandledExceptionView,
psbt_views, seed_views, settings_views, tools_views)
from seedsigner.views.view import NetworkMismatchErrorView, OptionDisabledView, PowerOffView, View
from seedsigner.views.view import ErrorView, NetworkMismatchErrorView, OptionDisabledView, PowerOffView, View

from .utils import ScreenshotComplete, ScreenshotRenderer

Expand Down Expand Up @@ -123,13 +123,7 @@ def test_generate_screenshots(target_locale):
PowerOptionsView,
RestartView,
PowerOffView,
NotYetImplementedView,
(UnhandledExceptionView, dict(error=UnhandledExceptionViewFood)),
(settings_views.SettingsIngestSettingsQRView, dict(data="settings::v1 name=factory_reset")),
NetworkMismatchErrorView,
(OptionDisabledView, dict(settings_attr=SettingsConstants.SETTING__MESSAGE_SIGNING)),


(settings_views.SettingsIngestSettingsQRView, dict(data="settings::v1 name=Uncle_Jim's_noob_mode")),
],
"Seed Views": [
seed_views.SeedsMenuView,
Expand Down Expand Up @@ -222,6 +216,18 @@ def test_generate_screenshots(target_locale):
#tools_views.ToolsAddressExplorerAddressView,
],
"Settings Views": settings_views_list,
"Misc Error Views": [
NotYetImplementedView,
(UnhandledExceptionView, dict(error=UnhandledExceptionViewFood)),
NetworkMismatchErrorView,
(OptionDisabledView, dict(settings_attr=SettingsConstants.SETTING__MESSAGE_SIGNING)),
(ErrorView, dict(
title="Error",
status_headline="Unknown QR Type",
text="QRCode is invalid or is a data format not yet supported.",
button_text="Back",
)),
],
}

readme = f"""# SeedSigner Screenshots\n"""
Expand Down

0 comments on commit 0883c8e

Please sign in to comment.