Moved the duplicated NEXT_URI constant from test_account.py and testlib_journal_entry.py to testlib.py.
This commit is contained in:
parent
7d084e570e
commit
361b18e411
@ -27,12 +27,9 @@ from flask import Flask
|
|||||||
from flask.testing import FlaskCliRunner
|
from flask.testing import FlaskCliRunner
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
from testlib import create_test_app, get_client, set_locale
|
from testlib import NEXT_URI, create_test_app, get_client, set_locale
|
||||||
from testlib_journal_entry import add_journal_entry
|
from testlib_journal_entry import add_journal_entry
|
||||||
|
|
||||||
NEXT_URI: str = "/_next"
|
|
||||||
"""The next URI."""
|
|
||||||
|
|
||||||
|
|
||||||
class AccountData:
|
class AccountData:
|
||||||
"""The account data."""
|
"""The account data."""
|
||||||
|
@ -28,8 +28,8 @@ from flask import Flask
|
|||||||
from flask.testing import FlaskCliRunner
|
from flask.testing import FlaskCliRunner
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
from testlib import create_test_app, get_client, set_locale
|
from testlib import NEXT_URI, create_test_app, get_client, set_locale
|
||||||
from testlib_journal_entry import add_journal_entry, NEXT_URI
|
from testlib_journal_entry import add_journal_entry
|
||||||
|
|
||||||
|
|
||||||
class CurrencyData:
|
class CurrencyData:
|
||||||
|
@ -24,8 +24,8 @@ from click.testing import Result
|
|||||||
from flask import Flask
|
from flask import Flask
|
||||||
from flask.testing import FlaskCliRunner
|
from flask.testing import FlaskCliRunner
|
||||||
|
|
||||||
from testlib import create_test_app, get_client
|
from testlib import NEXT_URI, create_test_app, get_client
|
||||||
from testlib_journal_entry import Accounts, NEXT_URI, add_journal_entry
|
from testlib_journal_entry import Accounts, add_journal_entry
|
||||||
|
|
||||||
|
|
||||||
class DescriptionEditorTestCase(unittest.TestCase):
|
class DescriptionEditorTestCase(unittest.TestCase):
|
||||||
|
@ -27,8 +27,8 @@ from flask import Flask
|
|||||||
from flask.testing import FlaskCliRunner
|
from flask.testing import FlaskCliRunner
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
from testlib import create_test_app, get_client
|
from testlib import NEXT_URI, create_test_app, get_client
|
||||||
from testlib_journal_entry import NEXT_URI, NON_EMPTY_NOTE, EMPTY_NOTE, \
|
from testlib_journal_entry import NON_EMPTY_NOTE, EMPTY_NOTE, \
|
||||||
Accounts, get_add_form, get_unchanged_update_form, get_update_form, \
|
Accounts, get_add_form, get_unchanged_update_form, get_update_form, \
|
||||||
match_journal_entry_detail, set_negative_amount, \
|
match_journal_entry_detail, set_negative_amount, \
|
||||||
remove_debit_in_a_currency, remove_credit_in_a_currency, add_journal_entry
|
remove_debit_in_a_currency, remove_credit_in_a_currency, add_journal_entry
|
||||||
|
@ -26,8 +26,8 @@ from flask import Flask
|
|||||||
from flask.testing import FlaskCliRunner
|
from flask.testing import FlaskCliRunner
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
from testlib import create_test_app, get_client
|
from testlib import NEXT_URI, create_test_app, get_client
|
||||||
from testlib_journal_entry import NEXT_URI, Accounts
|
from testlib_journal_entry import Accounts
|
||||||
from testlib_offset import TestData
|
from testlib_offset import TestData
|
||||||
|
|
||||||
PREFIX: str = "/accounting/options"
|
PREFIX: str = "/accounting/options"
|
||||||
|
@ -26,6 +26,8 @@ from test_site import create_app
|
|||||||
|
|
||||||
TEST_SERVER: str = "https://testserver"
|
TEST_SERVER: str = "https://testserver"
|
||||||
"""The test server URI."""
|
"""The test server URI."""
|
||||||
|
NEXT_URI: str = "/_next"
|
||||||
|
"""The next URI."""
|
||||||
|
|
||||||
|
|
||||||
def create_test_app() -> Flask:
|
def create_test_app() -> Flask:
|
||||||
|
@ -26,9 +26,8 @@ import httpx
|
|||||||
from flask import Flask
|
from flask import Flask
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
|
from testlib import NEXT_URI
|
||||||
|
|
||||||
NEXT_URI: str = "/_next"
|
|
||||||
"""The next URI."""
|
|
||||||
NON_EMPTY_NOTE: str = " This is \n\na test."
|
NON_EMPTY_NOTE: str = " This is \n\na test."
|
||||||
"""The stripped content of an non-empty note."""
|
"""The stripped content of an non-empty note."""
|
||||||
EMPTY_NOTE: str = " \n\n "
|
EMPTY_NOTE: str = " \n\n "
|
||||||
|
@ -26,8 +26,8 @@ import httpx
|
|||||||
from flask import Flask
|
from flask import Flask
|
||||||
|
|
||||||
from test_site import db
|
from test_site import db
|
||||||
from testlib_journal_entry import Accounts, match_journal_entry_detail, \
|
from testlib import NEXT_URI
|
||||||
NEXT_URI
|
from testlib_journal_entry import Accounts, match_journal_entry_detail
|
||||||
|
|
||||||
|
|
||||||
class JournalEntryLineItemData:
|
class JournalEntryLineItemData:
|
||||||
|
Loading…
Reference in New Issue
Block a user