-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Anders Fredrik Kiær
committed
Feb 24, 2020
1 parent
8765458
commit 636b3e2
Showing
3 changed files
with
82 additions
and
66 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
import dash | ||
from dash_html_components import Div | ||
import pytest | ||
|
||
from webviz_config.common_cache import CACHE | ||
from webviz_config.themes import default_theme | ||
|
||
|
||
class WebvizSinglePlugin: | ||
def __init__(self): | ||
self._app = dash.Dash(__name__) | ||
self._configure_app() | ||
|
||
def _configure_app(self): | ||
self._app.config.suppress_callback_exceptions = True | ||
CACHE.init_app(self._app.server) | ||
self._app.webviz_settings = {"theme": default_theme} | ||
|
||
@property | ||
def app(self): | ||
return self._app | ||
|
||
|
||
@pytest.fixture | ||
def webviz_single_plugin(): | ||
return WebvizSinglePlugin() |