diff options
author | Timothy Crosley <timothy.crosley@gmail.com> | 2015-02-04 23:49:44 -0500 |
---|---|---|
committer | Timothy Crosley <timothy.crosley@gmail.com> | 2015-02-04 23:49:44 -0500 |
commit | e6b2fd75a05cb03d7f7b574354820eebd818e414 (patch) | |
tree | b91272336a5b9d71070595042494f3b8156703fe | |
parent | 8bb294baa4cf7cb5f08fead24e13eac1330d5a73 (diff) | |
download | isort-feature/fix-issue-234.tar.gz |
Add a test for desired from_first behaviourfeature/fix-issue-234
-rw-r--r-- | test_isort.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test_isort.py b/test_isort.py index 7fde1b43..6e65b581 100644 --- a/test_isort.py +++ b/test_isort.py @@ -1194,3 +1194,10 @@ def test_from_ending(): test_input = "from foo import get_foo_from, get_foo\n" expected_output = "from foo import get_foo, get_foo_from\n" assert SortImports(file_contents=test_input).output == expected_output + + +def test_from_first(): + """Tests the setting from_first works correctly""" + test_input = "from os import path\nimport os\n" + assert SortImports(file_contents=test_input).output == test_input + |