sort pytest markers by length

Signed-off-by: Dan Ryan <dan@danryan.co>
This commit is contained in:
Dan Ryan
2019-03-18 00:45:40 -04:00
parent 6382f516e2
commit e16608c03f
+19 -19
View File
@@ -93,8 +93,8 @@ PyTest = "*"
assert lock['default']['pytest']['version'] == "==3.1.0"
@pytest.mark.keep_outdated
@pytest.mark.lock
@pytest.mark.keep_outdated
def test_keep_outdated_doesnt_remove_lockfile_entries(PipenvInstance, pypi):
with PipenvInstance(chdir=True, pypi=pypi) as p:
p._pipfile.add("requests", "==2.18.4")
@@ -106,8 +106,8 @@ def test_keep_outdated_doesnt_remove_lockfile_entries(PipenvInstance, pypi):
assert p.lockfile["default"]["colorama"]["markers"] == "os_name='FakeOS'"
@pytest.mark.keep_outdated
@pytest.mark.lock
@pytest.mark.keep_outdated
def test_keep_outdated_doesnt_upgrade_pipfile_pins(PipenvInstance, pypi):
with PipenvInstance(chdir=True, pypi=pypi) as p:
p._pipfile.add("urllib3", "==1.21.1")
@@ -198,8 +198,8 @@ allow_prereleases = true
@pytest.mark.lock
@pytest.mark.complex
@pytest.mark.maya
@pytest.mark.complex
@pytest.mark.needs_internet
@flaky
def test_complex_deps_lock_and_install_properly(PipenvInstance, pip_src_dir, pypi):
@@ -219,8 +219,8 @@ maya = "*"
assert c.return_code == 0
@pytest.mark.extras
@pytest.mark.lock
@pytest.mark.extras
def test_lock_extras_without_install(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi) as p:
with open(p.pipfile_path, 'w') as f:
@@ -241,11 +241,11 @@ requests = {version = "*", extras = ["socks"]}
assert "extra == 'socks'" not in c.out.strip()
@pytest.mark.extras
@pytest.mark.lock
@pytest.mark.extras
@pytest.mark.complex
@pytest.mark.skip(reason='Needs numpy to be mocked')
@pytest.mark.needs_internet
@pytest.mark.skip(reason='Needs numpy to be mocked')
def test_complex_lock_deep_extras(PipenvInstance, pypi):
# records[pandas] requires tablib[pandas] which requires pandas.
# This uses the real PyPI; Pandas has too many requirements to mock.
@@ -266,10 +266,10 @@ records = {extras = ["pandas"], version = "==0.5.2"}
assert 'pandas' in p.lockfile['default']
@pytest.mark.skip_lock
@pytest.mark.index
@pytest.mark.needs_internet
@pytest.mark.install # private indexes need to be uncached for resolution
@pytest.mark.skip_lock
@pytest.mark.needs_internet
def test_private_index_skip_lock(PipenvInstance):
with PipenvInstance() as p:
with open(p.pipfile_path, 'w') as f:
@@ -293,10 +293,10 @@ requests = "*"
assert c.return_code == 0
@pytest.mark.requirements
@pytest.mark.lock
@pytest.mark.index
@pytest.mark.install # private indexes need to be uncached for resolution
@pytest.mark.requirements
@pytest.mark.needs_internet
def test_private_index_lock_requirements(PipenvInstance):
# Don't use the local fake pypi
@@ -326,10 +326,10 @@ requests = "*"
assert '--extra-index-url https://test.pypi.org/simple' in c.out.strip()
@pytest.mark.requirements
@pytest.mark.lock
@pytest.mark.index
@pytest.mark.install # private indexes need to be uncached for resolution
@pytest.mark.requirements
@pytest.mark.needs_internet
def test_private_index_mirror_lock_requirements(PipenvInstance):
# Don't use the local fake pypi
@@ -366,8 +366,8 @@ requests = "*"
assert '--extra-index-url {}'.format(mirror_url) not in c.out.strip()
@pytest.mark.install
@pytest.mark.index
@pytest.mark.install
def test_lock_updated_source(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi) as p:
@@ -402,8 +402,8 @@ requests = "==2.14.0"
assert 'requests' in p.lockfile['default']
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
@pytest.mark.needs_internet
def test_lock_editable_vcs_without_install(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
@@ -421,8 +421,8 @@ requests = {git = "https://github.com/requests/requests.git", ref = "master", ed
assert c.return_code == 0
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
@pytest.mark.needs_internet
def test_lock_editable_vcs_with_ref_in_git(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
@@ -439,8 +439,8 @@ requests = {git = "https://github.com/requests/requests.git@883caaf", editable =
assert c.return_code == 0
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
@pytest.mark.needs_internet
def test_lock_editable_vcs_with_ref(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
@@ -457,9 +457,9 @@ requests = {git = "https://github.com/requests/requests.git", ref = "883caaf", e
assert c.return_code == 0
@pytest.mark.extras
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
@pytest.mark.extras
@pytest.mark.needs_internet
def test_lock_editable_vcs_with_extras_without_install(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
@@ -478,8 +478,8 @@ requests = {git = "https://github.com/requests/requests.git", editable = true, e
assert c.return_code == 0
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
@pytest.mark.needs_internet
def test_lock_editable_vcs_with_markers_without_install(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
@@ -541,8 +541,8 @@ def test_lockfile_with_empty_dict(PipenvInstance):
@pytest.mark.lock
@pytest.mark.skip_lock
@pytest.mark.install
@pytest.mark.skip_lock
def test_lock_with_incomplete_source(PipenvInstance, pypi):
with PipenvInstance(pypi=pypi, chdir=True) as p:
with open(p.pipfile_path, 'w') as f:
@@ -596,8 +596,8 @@ def test_lock_missing_cache_entries_gets_all_hashes(monkeypatch, PipenvInstance,
assert len(p.lockfile["default"]["scandir"]["hashes"]) > 1
@pytest.mark.lock
@pytest.mark.vcs
@pytest.mark.lock
def test_vcs_lock_respects_top_level_pins(PipenvInstance, pypi):
"""Test that locking VCS dependencies respects top level packages pinned in Pipfiles"""