summaryrefslogtreecommitdiff
path: root/tests_isolated
diff options
context:
space:
mode:
authorEric Lin <anselor@gmail.com>2021-01-05 11:29:39 -0500
committeranselor <anselor@gmail.com>2021-01-22 10:40:50 -0500
commita3b1b6ddf81cdc0b253f15feeb167ff348afd14f (patch)
tree2556f4aa57d02e12526949c08cf032c3e1a67d11 /tests_isolated
parentc1859045c8d439932fac9ceb5203a400db609533 (diff)
downloadcmd2-git-a3b1b6ddf81cdc0b253f15feeb167ff348afd14f.tar.gz
Changed isort to force wrapping of imports to reduce merge conflicts from minor import changes.
Diffstat (limited to 'tests_isolated')
-rw-r--r--tests_isolated/test_commandset/conftest.py29
-rw-r--r--tests_isolated/test_commandset/test_argparse_subcommands.py6
-rw-r--r--tests_isolated/test_commandset/test_categories.py9
-rw-r--r--tests_isolated/test_commandset/test_commandset.py18
4 files changed, 48 insertions, 14 deletions
diff --git a/tests_isolated/test_commandset/conftest.py b/tests_isolated/test_commandset/conftest.py
index 037be199..e6050f8d 100644
--- a/tests_isolated/test_commandset/conftest.py
+++ b/tests_isolated/test_commandset/conftest.py
@@ -3,15 +3,30 @@
Cmd2 unit/functional testing
"""
import sys
-from contextlib import redirect_stderr, redirect_stdout
-from typing import List, Optional, Union
-from unittest import mock
-
-from pytest import fixture
+from contextlib import (
+ redirect_stderr,
+ redirect_stdout,
+)
+from typing import (
+ List,
+ Optional,
+ Union,
+)
+from unittest import (
+ mock,
+)
+
+from pytest import (
+ fixture,
+)
import cmd2
-from cmd2_ext_test import ExternalTestMixin
-from cmd2.utils import StdSim
+from cmd2.utils import (
+ StdSim,
+)
+from cmd2_ext_test import (
+ ExternalTestMixin,
+)
# Prefer statically linked gnureadline if available (for macOS compatibility due to issues with libedit)
try:
diff --git a/tests_isolated/test_commandset/test_argparse_subcommands.py b/tests_isolated/test_commandset/test_argparse_subcommands.py
index bd2bed42..9618a53a 100644
--- a/tests_isolated/test_commandset/test_argparse_subcommands.py
+++ b/tests_isolated/test_commandset/test_argparse_subcommands.py
@@ -9,7 +9,11 @@ import argparse
import pytest
import cmd2
-from .conftest import run_cmd, WithCommandSets
+
+from .conftest import (
+ WithCommandSets,
+ run_cmd,
+)
class SubcommandSet(cmd2.CommandSet):
diff --git a/tests_isolated/test_commandset/test_categories.py b/tests_isolated/test_commandset/test_categories.py
index c266e0d4..905d68a8 100644
--- a/tests_isolated/test_commandset/test_categories.py
+++ b/tests_isolated/test_commandset/test_categories.py
@@ -3,10 +3,15 @@
"""
Simple example demonstrating basic CommandSet usage.
"""
-from typing import Any
+from typing import (
+ Any,
+)
import cmd2
-from cmd2 import CommandSet, with_default_category
+from cmd2 import (
+ CommandSet,
+ with_default_category,
+)
@with_default_category('Default Category')
diff --git a/tests_isolated/test_commandset/test_commandset.py b/tests_isolated/test_commandset/test_commandset.py
index 21cce8bf..7a192888 100644
--- a/tests_isolated/test_commandset/test_commandset.py
+++ b/tests_isolated/test_commandset/test_commandset.py
@@ -5,14 +5,24 @@ Test CommandSet
"""
import argparse
-from typing import List
+from typing import (
+ List,
+)
import pytest
import cmd2
-from cmd2 import utils
-from .conftest import complete_tester, WithCommandSets
-from cmd2.exceptions import CommandSetRegistrationError
+from cmd2 import (
+ utils,
+)
+from cmd2.exceptions import (
+ CommandSetRegistrationError,
+)
+
+from .conftest import (
+ WithCommandSets,
+ complete_tester,
+)
class CommandSetBase(cmd2.CommandSet):