Skip to content

Commit

Permalink
Import globally rather than per-test
Browse files Browse the repository at this point in the history
  • Loading branch information
kpinc committed Aug 30, 2024
1 parent bd9dcd4 commit c7072ae
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tests/test_scripts/test_common.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
import pytest
import unittest

import pyramid.scripts.common


class TestParseVars(unittest.TestCase):
def test_parse_vars_good(self):
Expand All @@ -19,15 +21,11 @@ def test_parse_vars_bad(self):


def test_get_config_loader_raises():
from pyramid.scripts.common import get_config_loader

with pytest.raises(PlasterError):
get_config_loader('invalidscheme:/foo')
pyramid.scripts.common.get_config_loader('invalidscheme:/foo')


def test_get_config_loader_calls():
from pyramid.scripts.common import get_config_loader

def reporter(text):
nonlocal reporter_called
reporter_called = True
Expand Down

0 comments on commit c7072ae

Please sign in to comment.