repo_id
string
cross_repo_split
string
commit_index
int32
commit_sha
string
in_repo_split
string
test_file
string
file_split
string
split_group
string
lineno
int32
col_offset
int32
assertion_type
string
test_function
string
prefix
large_string
target
string
assertion_event_type
string
assertion_event_id
string
assertion_anchor
large_string
old_target
string
old_lineno
int32
old_col_offset
int32
wemake-services/wemake-python-styleguide
train
373
398f5bed0e660629a9dbd8da1302d064de3b9cd3
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_wrong_names.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_wrong_names.py
57
4
assert_*
test_name_in_forbidden_domain_names_option
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'value', 'no', 'data', ]) def test_wrong_variable_name( ...
[WrongVariableNameViolation])
modified
09a5344c75f8a1fb18bc90fe39baefdf3b9f8a4ebb6ff99d8e2bf5d6ddbf3d1f
assert_*|test_name_in_forbidden_domain_names_option|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'value', 'no', 'data', ]) de...
[WrongVariableNameViolation])
57
4
wemake-services/wemake-python-styleguide
train
373
398f5bed0e660629a9dbd8da1302d064de3b9cd3
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_wrong_names.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_wrong_names.py
58
4
assert_*
test_name_in_forbidden_domain_names_option
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'value', 'no', 'data', ]) def test_wrong_variable_name( ...
forbidden_name)
modified
d0384e1e821283353afaa24debc1c370ae17fa7248ca96005d3cd758208fb231
assert_*|test_name_in_forbidden_domain_names_option|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'value', 'no', 'data', ]) de...
forbidden_name)
58
4
wemake-services/wemake-python-styleguide
train
375
be446d3027b069cc811ffab359f963ebba0f2c9a
train
tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
52
4
assert_*
test_same_alias_import_without_control
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.parametrize('code', [ reg...
[SameAliasImportViolation])
modified
243c095bbbdbbc9afa3ac516474768e21088f30310b5522237dc45a1c591c4e2
assert_*|test_same_alias_import_without_control|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}'...
[SameAliasImportViolation])
52
4
wemake-services/wemake-python-styleguide
train
375
be446d3027b069cc811ffab359f963ebba0f2c9a
train
tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
53
4
assert_*
test_same_alias_import_without_control
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.parametrize('code', [ reg...
same_alias)
modified
c91ef39b7387d9b3cea432484b4259b5d0c23c100213bbbe8d57113086da6b54
assert_*|test_same_alias_import_without_control|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}'...
same_alias)
53
4
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
254
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
bab16750debae9b36f70bb40c69b1f609c7662e292a1e32c353886884f629173
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
254
8
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
257
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
312671d234b60ee9bc48861fcba309b3da3559d5d71ef55c4bc88cb62d03a663
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
257
8
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
286
4
assert
test_noqa_fixture_disabled
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
modified
e8fbeb0b90dba44f8621b54c349f2228fcddf2c2c1cec929ce9654760432a335
assert|test_noqa_fixture_disabled|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wem...
len(all_violations)
286
4
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
316
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
modified
c57aa69a47e9c8946a35c9d0e548653cfcadfb5be3cfffd30b349ac30ddf28c6
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
len(all_controlled_violations)
316
4
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
30
4
assert_*
test_same_alias_import
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.parametrize('code', [ reg...
[SameAliasImportViolation])
modified
6743a75caa16183a4486119c188a0969258e507e768f4f09106e4a316e4e2ad0
assert_*|test_same_alias_import|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.pa...
[])
30
4
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
52
4
assert_*
test_same_alias_import_with_control
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.parametrize('code', [ reg...
[SameAliasImportViolation])
added
5f4fadb49c1fcc48c353b37099075c74c9240f3d449b83cbeff9cc94616c91c4
assert_*|test_same_alias_import_with_control|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @p...
null
null
null
wemake-services/wemake-python-styleguide
train
376
f8af7ff693e5cf7b4722346ef5c4d224db66ed52
train
tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_imports/test_same_alias_import.py
53
4
assert_*
test_same_alias_import_with_control
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @pytest.mark.parametrize('code', [ reg...
same_alias)
added
a419fe1a73593279cb3a444a53a75ba7b34877319fc4f5942af666b90c0fdb56
assert_*|test_same_alias_import_with_control|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import SameAliasImportViolation from wemake_python_styleguide.visitors.ast.imports import WrongImportVisitor regular_import = 'import os as {0}' from_import = 'from sys import os as {0}' @p...
null
null
null
wemake-services/wemake-python-styleguide
train
377
2783498e47ca5610ceda4a919454f5d6ab866d6c
train
tests/test_visitors/test_decorators/test_alias_decorator.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_decorators/test_alias_decorator.py
18
9
pytest.raises
test_raises_for_duplicates
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicat...
ValueError)
added
f32d44e1c8c4231d5f174abc1858d574b07674df942d459824e40e0849fa9d85
pytest.raises|test_raises_for_duplicates|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for du...
null
null
null
wemake-services/wemake-python-styleguide
train
377
2783498e47ca5610ceda4a919454f5d6ab866d6c
train
tests/test_visitors/test_decorators/test_alias_decorator.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_decorators/test_alias_decorator.py
24
9
pytest.raises
test_useless_alias
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicat...
ValueError)
added
529989c3d233c020318a1c7d5fcf2751ae5e6204ebbf3a44c658c0b24b536d35
pytest.raises|test_useless_alias|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicates...
null
null
null
wemake-services/wemake-python-styleguide
train
377
2783498e47ca5610ceda4a919454f5d6ab866d6c
train
tests/test_visitors/test_decorators/test_alias_decorator.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_decorators/test_alias_decorator.py
30
9
pytest.raises
test_raises_for_missing_alias
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicat...
AttributeError)
added
e68807ceed01d8fcf17e701b0b693a62c74e2a1ecd8f9c08fafb6852793fe7aa
pytest.raises|test_raises_for_missing_alias|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for...
null
null
null
wemake-services/wemake-python-styleguide
train
377
2783498e47ca5610ceda4a919454f5d6ab866d6c
train
tests/test_visitors/test_decorators/test_alias_decorator.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_decorators/test_alias_decorator.py
36
9
pytest.raises
test_raises_for_existing_alias
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicat...
AttributeError)
added
8951630daa4c299e16cc9def620d2a50ea2e10f8f452bec3eb072541767c2936
pytest.raises|test_raises_for_existing_alias|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias class _HasAliasedProp(object): def existing(self): return None def first(self): return None def test_raises_for_duplicates(): """Ensures that decorator raises an exception fo...
null
null
null
wemake-services/wemake-python-styleguide
train
378
9223fdc487a6e1dfc7ecffd04faee90e945fd2a2
train
tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
55
4
assert_*
test_yield_keyword_in_comprehension
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVisitor, ) list_comprehension = """ de...
[YieldInComprehensionViolation])
added
c162ca714414288dd656b5e49618aa9047ae8241993f7618b5e863bacaca9eda
assert_*|test_yield_keyword_in_comprehension|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVisi...
null
null
null
wemake-services/wemake-python-styleguide
train
378
9223fdc487a6e1dfc7ecffd04faee90e945fd2a2
train
tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
78
9
pytest.raises
test_yield_keyword_in_comprehension_syntax_error
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVisitor, ) list_comprehension = """ de...
SyntaxError)
added
e1826f7c4cbc3391314775773979c4c5cf64df4bd6ce92c84912f30e28795223
pytest.raises|test_yield_keyword_in_comprehension_syntax_error|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( Wron...
null
null
null
wemake-services/wemake-python-styleguide
train
379
d00f586a9346abbf00c6ff60ba00b7486a34a56c
train
tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
78
9
pytest.raises
test_yield_keyword_syntax_error
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVisitor, ) list_comprehension = """ de...
SyntaxError)
added
d72d5e70630a5f49a04871f72589581772e0f4c6bbb9a612d3c636331bb4993c
pytest.raises|test_yield_keyword_syntax_error|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVis...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
236
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
test_function(5)
added
d39bad7c92a92db0ec1b67acf256e62b6a56ef6759374ba72d5d2206a4ee2275
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
237
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
test_function(6)
added
7cd5997dfa023be5f19cc0ed30de436cf47a361a29ba751ec57259500c2cbf93
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
319
0
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
hex_number
added
10f4067062c10c4b94955b8b1fea05ea6f39e43cdb164bb6bdb08519189e49e1
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
258
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
added
5634f79bf32fec20ebf7238499992d0fee11e39eec6e9d5b0984c16e8c47796c
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
320
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
added
cd2f6f9e2f8bb2494c86a9d74580d3f0d45730f70439dce5e1f1a1dd1cc03e58
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
null
null
null
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/test_formatter/test_formatter_output.py
train
wemake-services/wemake-python-styleguide:tests/test_formatter/test_formatter_output.py
77
4
assert_*
test_formatter
# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when running ``pytest``. ...
'formatter_{0}'.format(output))
modified
2f0d4f0937705f8157d03c97bb7802c615f7ab7f8aa2ceca6b3221be0082b805
assert_*|test_formatter|# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when ...
'formatter_{0}'.format(output))
77
4
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/test_formatter/test_formatter_output.py
train
wemake-services/wemake-python-styleguide:tests/test_formatter/test_formatter_output.py
111
4
assert_*
test_formatter_correct
# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when running ``pytest``. ...
'formatter_correct_{0}'.format(output))
modified
242862c2a0bde47088790befb308cc810b9787a513b63a710a4d5593debbf0cb
assert_*|test_formatter_correct|# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` fla...
'formatter_correct_{0}'.format(output))
111
4
wemake-services/wemake-python-styleguide
train
380
3706ed7f52db4a8b2c15592cf2a6bbae529eb0c4
train
tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_comprehensions/test_yield_inside_comprehension.py
75
9
pytest.raises
test_yield_keyword_syntax_error
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVisitor, ) list_comprehension = """ de...
SyntaxError)
modified
8cac3b31fecdfab3a9708fb0dffa84bd5e4f55f39a9176ef6a3e0a54361fdd01
pytest.raises|test_yield_keyword_syntax_error|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( YieldInComprehensionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongComprehensionVis...
SyntaxError)
78
9
wemake-services/wemake-python-styleguide
train
381
181aec97aeb8da8b392928f9e81ddd1c028b10aa
train
tests/test_formatter/test_formatter_output.py
train
wemake-services/wemake-python-styleguide:tests/test_formatter/test_formatter_output.py
80
4
assert_*
test_formatter
# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when running ``pytest``. ...
'formatter_{0}'.format(output))
modified
a977611273ffe231e463ac4960a4644bd3669365048599a40494012d1883513f
assert_*|test_formatter|# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when ...
'formatter_{0}'.format(output))
77
4
wemake-services/wemake-python-styleguide
train
381
181aec97aeb8da8b392928f9e81ddd1c028b10aa
train
tests/test_formatter/test_formatter_output.py
train
wemake-services/wemake-python-styleguide:tests/test_formatter/test_formatter_output.py
114
4
assert_*
test_formatter_correct
# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` flag, when running ``pytest``. ...
'formatter_correct_{0}'.format(output))
modified
616fcba040927defa38d8cdbf4054493f3b32576387a6cbbdf75c7cbb743ac1a
assert_*|test_formatter_correct|# -*- coding: utf-8 -*- """ We use direct string assertiong on the formatter. So, no unit tests for formatter, only e2e ones. We use ``snapshottest`` to render and assert equality of the output: https://github.com/syrusakbary/snapshottest To update snapshots use ``--snapshot-update`` fla...
'formatter_correct_{0}'.format(output))
111
4
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
294
0
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
octal_number
added
0518ae2f260c5d050ce4c83157cca3970d822c61b2d29d2e0e2570b514561dd3
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
null
null
null
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
305
0
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
hex_number
modified
ad1e399cc8255a0f6bc150c38ac1e47771c4838a445a8b601e0dfc15b23e08e5
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
octal_number
308
0
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
258
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
e2bf973b8e0311039c27c21210178cdbec429c293ea6d08fb785eda00e08e279
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
258
8
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
261
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
9371a1a89779ed9f59fd26d2a62bad2c095fd4f9cd14713c1100dbca0a375c9b
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
261
8
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
290
4
assert
test_noqa_fixture_disabled
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
modified
5edcdcaa0b7b72de53840c8bde3a8346df76bd8aa32bceff207d8789aac41c2f
assert|test_noqa_fixture_disabled|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wem...
len(all_violations)
290
4
wemake-services/wemake-python-styleguide
train
382
bc7bcfdf4a55a90336e74cd25b9257fd28b0874b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
320
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
modified
3cb1b6d7641524a1b26d4e980c32009a452702af7ff3212065f97eaf6198c1b7
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
len(all_controlled_violations)
320
4
wemake-services/wemake-python-styleguide
train
383
a415339ed47de3ff03754bddd9b57316f494dfb1
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
284
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
added
5ed191733ddaf435255b5a0f3ff58f62831ca0d7621023dd72eef2e0c34a37ad
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
null
null
null
wemake-services/wemake-python-styleguide
train
383
a415339ed47de3ff03754bddd9b57316f494dfb1
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
285
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors.get(found_error)
added
abc9734bec5012fb3fd665639b8bb14f18bcefd4e094e3d9ed74f334990fb836
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
null
null
null
wemake-services/wemake-python-styleguide
train
383
a415339ed47de3ff03754bddd9b57316f494dfb1
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
294
4
assert
test_codes
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
added
739da009291ad30b2d2b7923e566c21d9b5d296827bed79a939b5bd10ebd4645
assert|test_codes|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-style...
null
null
null
wemake-services/wemake-python-styleguide
train
383
a415339ed47de3ff03754bddd9b57316f494dfb1
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
368
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
added
0f8c41c6b62f56304b7cfc6b072510ff00121076cd12dd7aa6edcc08200de7ac
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
null
null
null
wemake-services/wemake-python-styleguide
train
384
2b4d12f16517ecda8e330f5f3a376b7e1b7ea183
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
281
12
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
4ad8cc814ff04f2cd0f7f3deffbcccc1a011bfaac6825204aacdcbdaeeef2566
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
281
12
wemake-services/wemake-python-styleguide
train
384
2b4d12f16517ecda8e330f5f3a376b7e1b7ea183
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
285
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors.get(found_error)
modified
fb8917aabe0cf7cc44adb7c94523a67685f8fe1788eb11c074a34687e2083a37
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors.get(found_error)
285
8
wemake-services/wemake-python-styleguide
train
384
2b4d12f16517ecda8e330f5f3a376b7e1b7ea183
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
294
4
assert
test_codes
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
modified
e396db584bac8a28d562aa4f2e5e70366dc661bfff17b1e74124d1b44011fc4f
assert|test_codes|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-style...
len(all_violations)
294
4
wemake-services/wemake-python-styleguide
train
384
2b4d12f16517ecda8e330f5f3a376b7e1b7ea183
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
368
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
modified
e277f29b767fe41cf6aa296f4200c95cea4464df1310f0b8511ceff7f0c91ba7
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
len(all_controlled_violations)
368
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_constant_compares/test_falsy_constant.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_constant_compares/test_falsy_constant.py
55
4
assert_*
test_falsy_constant_is
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', '[]'), ('some', ...
[ FalsyConstantCompareViolation, WrongIsCompareViolation, ])
modified
a6b7a6a9543254ae1992b5a077e36acf3e233f04d892df8f480b36370991bdbe
assert_*|test_falsy_constant_is|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', '[]'), ...
[ FalsyConstantCompareViolation, WrongIsCompareViolation, ])
54
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_constant_compares/test_falsy_constant.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_constant_compares/test_falsy_constant.py
113
4
assert_*
test_correct_constant_compare
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', '[]'), ('some', ...
(WrongIsCompareViolation,))
modified
e017b349daeddd24ce97bbabd2082367f8e17e797c41ecf37a5afb6daf0fff9e
assert_*|test_correct_constant_compare|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', ...
(WrongIsCompareViolation,))
111
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_constant_compares/test_is_constant_compare.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_constant_compares/test_is_constant_compare.py
55
4
assert_*
test_wrong_constant_is
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', '[1, 2]'), ('som...
( FalsyConstantCompareViolation, ))
modified
b2dee5c41ff4b7a0c36c38d0608133dec23c42e0d69bece91566d38a8a7bf8f7
assert_*|test_wrong_constant_is|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.refactoring import ( FalsyConstantCompareViolation, WrongIsCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongConstantCompareVisitor, ) wrong_comparators = ( ('some', '[1, 2]...
( FalsyConstantCompareViolation, ))
54
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_literal.py
val
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_literal.py
58
4
assert_*
test_literal
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ConstantCompareViolation, ReversedComplexCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor if_with_chained_compares1 = 'if 0 < {0} < {1}: ...' if_with_chained_...
[ConstantCompareViolation])
modified
f01b4a0ec7f86ecbc91de7c1c892b559cc83a37ca0ff133ca56cbf600688099e
assert_*|test_literal|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ConstantCompareViolation, ReversedComplexCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor if_with_chained_compares1 = 'if 0 < {0} < {1}: ...' if_wi...
[ConstantCompareViolation])
56
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_literal.py
val
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_literal.py
82
4
assert_*
test_literal_special1
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ConstantCompareViolation, ReversedComplexCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor if_with_chained_compares1 = 'if 0 < {0} < {1}: ...' if_with_chained_...
[ConstantCompareViolation])
modified
656b953ef6d8326ce74319fc020679dc08dc9011ef7c134055c9432768b4e78d
assert_*|test_literal_special1|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ConstantCompareViolation, ReversedComplexCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor if_with_chained_compares1 = 'if 0 < {0} < {1}: ....
[ConstantCompareViolation])
80
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_order.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_order.py
93
4
assert_*
test_compare_wrong_order
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( CompareOrderViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongComparisionOrderVisitor, ) regression577 = """ async def function(): assert await _coroutine(1) == Success(1) """ ...
[CompareOrderViolation])
modified
87e9581a509fd3fd807f865ba49c999f2dfa3019a3883968f44de39672050c86
assert_*|test_compare_wrong_order|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( CompareOrderViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongComparisionOrderVisitor, ) regression577 = """ async def function(): assert await _coroutine(1)...
[CompareOrderViolation])
91
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_order.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_order.py
118
4
assert_*
test_compare_wrong_order_multiple
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( CompareOrderViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongComparisionOrderVisitor, ) regression577 = """ async def function(): assert await _coroutine(1) == Success(1) """ ...
[ CompareOrderViolation, CompareOrderViolation, ])
modified
59c26afba9fd1ab880f1827e5dbb9c8ac4a04b21b89658ab18ab3f00d4cd55a8
assert_*|test_compare_wrong_order_multiple|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( CompareOrderViolation, ) from wemake_python_styleguide.visitors.ast.compares import ( WrongComparisionOrderVisitor, ) regression577 = """ async def function(): assert await _cor...
[ CompareOrderViolation, CompareOrderViolation, ])
116
4
wemake-services/wemake-python-styleguide
train
385
be3a22aefd6a038a012e0c5cc7432b4a8ac7dda3
train
tests/test_visitors/test_ast/test_compares/test_redundant.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_compares/test_redundant.py
63
4
assert_*
test_useless
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( UselessCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor create_variables = """ variable = 1 another_variable = 2 {0} """ @pytest.mark.filterwarnings('ignore::Sy...
[UselessCompareViolation])
modified
a6864d35b34141b44e450010ccb2c960b5f80ff23b57105f40cf245617e3a777
assert_*|test_useless|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( UselessCompareViolation, ) from wemake_python_styleguide.visitors.ast.compares import CompareSanityVisitor create_variables = """ variable = 1 another_variable = 2 {0} """ @pytest.mark.filterwarning...
[UselessCompareViolation])
62
4
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
122
4
assert_*
test_collection_with_pure_duplicate
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_template = """ {{ *{{ {0}...
[NonUniqueItemsInHashViolation])
modified
c660c36dd3f6fddbbc4c68ff782bb4b4b63ba6aa2fcfda720bdf7e43ba8e76f1
assert_*|test_collection_with_pure_duplicate|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_tem...
[NonUniqueItemsInHashViolation])
121
4
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
147
4
assert_*
test_set_with_pure_duplicate
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_template = """ {{ *{{ {0}...
[NonUniqueItemsInHashViolation])
modified
bdafabe49c0957360112265d69b9f1e1de9e067b1fc05e48abfb385d361114c2
assert_*|test_set_with_pure_duplicate|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_template =...
[NonUniqueItemsInHashViolation])
146
4
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_elements.py
176
4
assert_*
test_set_with_similar_values
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_template = """ {{ *{{ {0}...
[NonUniqueItemsInHashViolation])
modified
43b3ae010086d3d9c794c12d368b8b13f6bd72712cbd263daee3da7380c1d6e9
assert_*|test_set_with_similar_values|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_template =...
[NonUniqueItemsInHashViolation])
175
4
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
79
4
assert
test_correct_comments
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = """# -*- coding: utf-8 -*...
False
added
1a094d45d05ce1554ea08b647f5310dc7e27649607e29fff136f485fffb84383
assert|test_correct_comments|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = """# -*-...
null
null
null
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
101
4
assert_*
test_incorrect_coding_comment
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = """# -*- coding: utf-8 -*...
[EmptyLineAfterCodingViolation])
added
f8e122ce592a7f9a66ed49ad92e8be852031b7b213ea33af0bfd051194f6a0cb
assert_*|test_incorrect_coding_comment|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding ...
null
null
null
wemake-services/wemake-python-styleguide
train
386
690b812c8b58d76a35b2767b6c7a6907e4979a84
train
tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
102
4
assert
test_incorrect_coding_comment
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = """# -*- coding: utf-8 -*...
False
added
347225e29f392d1f3fba767b1e9d4581c17acf1cb917aca6e46fcf2c3e775635
assert|test_incorrect_coding_comment|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = ...
null
null
null
wemake-services/wemake-python-styleguide
train
387
fab2d9eb1a13614df33ecd242c3770a12fe543a2
train
tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_comments/test_empty_line_after_coding.py
102
4
assert_*
test_incorrect_coding_comment
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding = """# -*- coding: utf-8 -*...
[EmptyLineAfterCodingViolation])
modified
19915c002d8caa14e07905f243d3a9ce14c3f6c9cddc34ce847e8e30d65d8dba
assert_*|test_incorrect_coding_comment|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( EmptyLineAfterCodingViolation, ) from wemake_python_styleguide.visitors.tokenize.comments import ( FileMagicCommentsVisitor, ) # Correct: empty_module = '' empty_module_with_coding ...
[EmptyLineAfterCodingViolation])
101
4
wemake-services/wemake-python-styleguide
train
388
2c518e7b7abddc29a2f6fbf63d9e5ce5a3d17d75
train
tests/test_visitors/test_ast/test_operators/test_walrus.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_operators/test_walrus.py
80
4
assert_*
test_walrus
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.consistency import WalrusViolation from wemake_python_styleguide.visitors.ast.operators import WalrusVisitor # Correct: correct_assignment = 'x = 1' correct_if_condition = """ som...
[WalrusViolation])
added
1b939c3a99836f847926c536933d4de060e4dd2a644a0587d3a2a38659404278
assert_*|test_walrus|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.consistency import WalrusViolation from wemake_python_styleguide.visitors.ast.operators import WalrusVisitor # Correct: correct_assignment = 'x = 1' correct_if_c...
null
null
null
wemake-services/wemake-python-styleguide
train
389
8940c5195a971ab23c7ab2575a1505dc3e0bf56b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
289
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
added
c2625a87bfc4ed913180fde0cb3542d4c1f437966df66c828f73a87cbcde03ff
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
null
null
null
wemake-services/wemake-python-styleguide
train
389
8940c5195a971ab23c7ab2575a1505dc3e0bf56b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
290
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors.get(found_error)
modified
604c315437f9b97ac023b721327d80445e846c1607c21456b3f9db5b9605cd06
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
set()
287
4
wemake-services/wemake-python-styleguide
train
389
8940c5195a971ab23c7ab2575a1505dc3e0bf56b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
299
4
assert
test_codes
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
added
8152eae543f3dedb97d48c0a60325f00dbba25dfc59a13531ae5885e962998d8
assert|test_codes|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-style...
null
null
null
wemake-services/wemake-python-styleguide
train
389
8940c5195a971ab23c7ab2575a1505dc3e0bf56b
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
373
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
added
0ac80ba7aac60fa8d8d6417cb2ac26f473898bdcdb51a96210070a6e2275baf3
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
null
null
null
wemake-services/wemake-python-styleguide
train
391
da325e0820435f7361dca33920922d7564480698
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
232
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # n...
test_function(1)
modified
56c2ff06ddb55071dcc196ce0f9851dcf2112b51e073d1e395af06426a849bc4
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noq...
test_function(1)
232
4
wemake-services/wemake-python-styleguide
train
391
da325e0820435f7361dca33920922d7564480698
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
233
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # n...
test_function(2)
modified
f30c440246221332972d6e59ba5f275376afe0081508272ee031adb81618a1b7
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noq...
test_function(2)
233
4
wemake-services/wemake-python-styleguide
train
391
da325e0820435f7361dca33920922d7564480698
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
235
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # n...
test_function(4)
modified
033a684840824bceb1e3ca81594b22c6ae1dd1672a73a99b35db8a6ee3e738bd
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noq...
test_function(4)
235
4
wemake-services/wemake-python-styleguide
train
391
da325e0820435f7361dca33920922d7564480698
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
237
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # n...
test_function(6)
modified
c97941967573b257ed907351af97987a95fc7ec638b21e9816584dd4bf9ef3e5
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import my_print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noq...
test_function(6)
237
4
wemake-services/wemake-python-styleguide
train
392
4720a66485b2db13644f00ad01a2f0036800dcda
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
233
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
test_function(2)
modified
e8aed093e3d2e93307a49b54db86a11a5d7a06391ae22f3bddf0647182567d1a
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
test_function(2)
233
4
wemake-services/wemake-python-styleguide
train
392
4720a66485b2db13644f00ad01a2f0036800dcda
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
235
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
test_function(4)
modified
93b0b4edb6129eb44c7c6961fa7313b1e299ef782c3f7ca143964eebfb9afa27
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
test_function(4)
235
4
wemake-services/wemake-python-styleguide
train
392
4720a66485b2db13644f00ad01a2f0036800dcda
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
236
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
test_function(5)
modified
36d0a14083218fc8e25c35558a5098c27a370d76142b6d5c996d15fa8f98021b
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
test_function(5)
236
4
wemake-services/wemake-python-styleguide
train
392
4720a66485b2db13644f00ad01a2f0036800dcda
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
294
0
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa...
octal_number
modified
6bfe2ab5f7003ac253ae04247c6f469b0e34e6a7b33be382374b4672dcff60ed
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some import _protected # noqa: ...
octal_number
294
0
wemake-services/wemake-python-styleguide
train
393
ae664f80171f8e8d47edaa2d6bf0e0901967c7b8
train
tests/test_logic/test_complexity/test_cognitive/test_cognitive_complexity.py
train
wemake-services/wemake-python-styleguide:tests/test_logic/test_complexity/test_cognitive/test_cognitive_complexity.py
160
4
assert
test_cognitive_complexity
# -*- coding: utf-8 -*- """ Test to ensure that we count cognitive complexity correctly. Adapted from https://github.com/Melevir/cognitive_complexity """ import pytest complexity1_1 = """ def f(a, b): if a: # +1 return 1 """ complexity1_2 = """ def f(a): return a * f(a - 1) # +1 for recursion """...
complexity
added
2ac19b2ea8939e70e42a8f8add6d810c0de7ceac11972722c98ce402fcdf2c20
assert|test_cognitive_complexity|# -*- coding: utf-8 -*- """ Test to ensure that we count cognitive complexity correctly. Adapted from https://github.com/Melevir/cognitive_complexity """ import pytest complexity1_1 = """ def f(a, b): if a: # +1 return 1 """ complexity1_2 = """ def f(a): return a * f(a - 1) # +1 for rec...
null
null
null
wemake-services/wemake-python-styleguide
train
393
ae664f80171f8e8d47edaa2d6bf0e0901967c7b8
train
tests/test_violations/test_codes.py
train
wemake-services/wemake-python-styleguide:tests/test_violations/test_codes.py
42
16
assert
test_no_holes
# -*- coding: utf-8 -*- def test_all_unique_violation_codes(all_violations): """Ensures that all violations have unique violation codes.""" codes = [] for violation in all_violations: codes.append(int(violation.code)) assert len(set(codes)) == len(all_violations) def test_all_violations_cor...
diff == 1 or diff > 2
added
a3eb6c445562c70d51d003b2939a94775446205b0b2fefad37df4e1fd95eb12b
assert|test_no_holes|# -*- coding: utf-8 -*- def test_all_unique_violation_codes(all_violations): """Ensures that all violations have unique violation codes.""" codes = [] for violation in all_violations: codes.append(int(violation.code)) assert len(set(codes)) == len(all_violations) def test_all_violations_correct_num...
null
null
null
wemake-services/wemake-python-styleguide
train
393
ae664f80171f8e8d47edaa2d6bf0e0901967c7b8
train
tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_average.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_average.py
91
4
assert_*
test_complex_cognitive_options
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_function = """ def literal_e...
[CognitiveModuleComplexityViolation])
modified
271d23680325aaf358d7a1641308ac7821f63c671e8964360cff58c909d1e98f
assert_*|test_complex_cognitive_options|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_fun...
[CognitiveModuleComplexityViolation])
91
4
wemake-services/wemake-python-styleguide
train
393
ae664f80171f8e8d47edaa2d6bf0e0901967c7b8
train
tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_score.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_score.py
91
4
assert_*
test_complex_cognitive_options
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_function = """ def literal_e...
[CognitiveComplexityViolation])
modified
c7104fb0f7db2b2f24dd128ca924730aa68ceb6b394bddbfca62a649b02748ea
assert_*|test_complex_cognitive_options|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_fun...
[CognitiveComplexityViolation])
91
4
wemake-services/wemake-python-styleguide
train
394
02841c80a7b16370e760757f761bc530db3d68a5
train
tests/test_logic/test_complexity/test_cognitive/conftest.py
test
wemake-services/wemake-python-styleguide:tests/test_logic/test_complexity/test_cognitive/conftest.py
34
8
assert
# -*- coding: utf-8 -*- """ Fixtures to make testing cognitive complexity easy. Policy for testing cognitive complexity: 1. Use a single function def in code samples 2. Write ``# +x`` comments on each line where addition happens Adapted from https://github.com/Melevir/cognitive_complexity """ import ast import py...
funcdef
added
f43f17d27fcd0b0b6ed6dd993f8fba0af66f262327e4c0aac12eac8a1b52e7cd
assert||# -*- coding: utf-8 -*- """ Fixtures to make testing cognitive complexity easy. Policy for testing cognitive complexity: 1. Use a single function def in code samples 2. Write ``# +x`` comments on each line where addition happens Adapted from https://github.com/Melevir/cognitive_complexity """ import ast import ...
null
null
null
wemake-services/wemake-python-styleguide
train
394
02841c80a7b16370e760757f761bc530db3d68a5
train
tests/test_logic/test_complexity/test_cognitive/test_cognitive_complexity.py
train
wemake-services/wemake-python-styleguide:tests/test_logic/test_complexity/test_cognitive/test_cognitive_complexity.py
178
4
assert
test_cognitive_complexity
# -*- coding: utf-8 -*- """ Test to ensure that we count cognitive complexity correctly. Adapted from https://github.com/Melevir/cognitive_complexity """ import pytest complexity1_1 = """ def f(a, b): if a: # +1 return 1 """ complexity1_2 = """ def f(a): return a * f(a - 1) # +1 for recursion """...
complexity
added
155a22920db0b7254fe0ce62681531a64dc77fa23488c301b51e7899d92cd9be
assert|test_cognitive_complexity|# -*- coding: utf-8 -*- """ Test to ensure that we count cognitive complexity correctly. Adapted from https://github.com/Melevir/cognitive_complexity """ import pytest complexity1_1 = """ def f(a, b): if a: # +1 return 1 """ complexity1_2 = """ def f(a): return a * f(a - 1) # +1 for rec...
null
null
null
wemake-services/wemake-python-styleguide
train
395
440bb9d39f4b4e5e4bdc20489d1ed25ab14bb718
train
tests/test_visitors/test_ast/test_classes/test_methods/test_useless_overwriting_method.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_classes/test_methods/test_useless_overwriting_method.py
146
4
assert_*
test_useless_overwriting
# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed = """ class Useless(object): ...
[oop.UselessOverwrittenMethodViolation])
added
ad1238d0b8d9002920fcd63a9d76d00b851ea5ffdb3fd672d03f106a56968dcc
assert_*|test_useless_overwriting|# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed ...
null
null
null
wemake-services/wemake-python-styleguide
train
395
440bb9d39f4b4e5e4bdc20489d1ed25ab14bb718
train
tests/test_visitors/test_ast/test_functions/test_useless_lambda.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_functions/test_useless_lambda.py
49
4
assert_*
test_incorrect_lambda_definition
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.refactoring import ( UselessLambdaViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( UselessLambdaDefinitionVisitor, ) template = '{0}: {1}' usele...
[UselessLambdaViolation])
added
b1ea6c0eca1cb37c5ba32333167c2a9252ce8134a256c58d3e8fee15c78ed79b
assert_*|test_incorrect_lambda_definition|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.refactoring import ( UselessLambdaViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( UselessLambdaDefinitionVisitor,...
null
null
null
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
288
12
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors
modified
fe3aac0705ca97600c4b0873d22f1d94591ce5be98779e121b5dfefec583b1d0
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors
286
12
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
292
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors.get(found_error)
modified
be54f9954f7bdb80df9437cf6f0b9ce6371930f300511dc2db1474eabee09e57
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors.get(found_error)
290
8
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
301
4
assert
test_codes
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_violations)
modified
bba46538d9c911c51cfca4f989bcbcafb4e9380c21e8aac95ea3b1fd66666f90
assert|test_codes|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-style...
len(all_violations)
299
4
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
375
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
modified
7d30eef157506faeac682f5c916cd61f6794da90efc3404cf049476843c56f0c
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
len(all_controlled_violations)
373
4
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_visitors/test_ast/test_functions/test_positional_only.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_functions/test_positional_only.py
99
4
assert_*
test_posonyargs
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( PositionalOnlyArgumentsViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( PositionalOnlyArgumentsVisitor, ) # Correct: corr...
[PositionalOnlyArgumentsViolation])
added
6904ac13e798db2c121e0eca34858c9b403b6143e48bae0c178375c20aafe20d
assert_*|test_posonyargs|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( PositionalOnlyArgumentsViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( PositionalOnlyArgumentsVisitor, ) #...
null
null
null
wemake-services/wemake-python-styleguide
train
396
45f57b31ad69dd2cbcd9ac9e1f4f150b27b4a392
train
tests/test_visitors/test_ast/test_operators/test_walrus.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_operators/test_walrus.py
79
4
assert_*
test_walrus
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.consistency import WalrusViolation from wemake_python_styleguide.visitors.ast.operators import WalrusVisitor # Correct: correct_assignment = 'x = 1' correct_if_condition = """ som...
[WalrusViolation])
added
317bab3be2042a63a86ea9b2b060899e5f7e61ba7877bb2ffcb2e692d1ee04e2
assert_*|test_walrus|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.consistency import WalrusViolation from wemake_python_styleguide.visitors.ast.operators import WalrusVisitor # Correct: correct_assignment = 'x = 1' correct_if_c...
null
null
null
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
233
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some ...
test_function(1)
modified
df50765935e937b5123e1e14a2ce1f8a1621c8ee1a4f1b56d58235f53115934c
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some im...
test_function(1)
232
4
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
236
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some ...
test_function(4)
modified
7ae5100ab95782db0dc40c7dd896ab532df9d4f89854dfe7262ba44cb3a518b8
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some im...
test_function(4)
235
4
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/fixtures/noqa/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa/noqa.py
238
4
assert
# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some ...
test_function(6)
modified
82a1749af1417c3b6cf98339e100d95db56d48963d796672e6d279594cd2d1ec
assert||# -*- coding: utf-8 -*- # noqa: WPS323 """ This file contains all possible violations. It is used for e2e tests. """ from __future__ import print_function # noqa: WPS422 from typing import List import os.path # noqa: WPS301 import sys as sys # noqa: WPS113 from _some import protected # noqa: WPS436 from some im...
test_function(6)
237
4
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
293
8
assert
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
errors.get(found_error)
modified
92f8aade247d94207bedada110a4dab9cfd620ef2ed817b9c8001fbaa8f192e8
assert||# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/...
errors.get(found_error)
292
8
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
376
4
assert
test_noqa_fixture_disabled_no_control
# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: https://wemake-python-stylegui.de/en/late...
len(all_controlled_violations)
modified
143157e61d92a4b4591c4a1b8fa0c2e63404c73e8360e746fa8d5639a6143365
assert|test_noqa_fixture_disabled_no_control|# -*- coding: utf-8 -*- """ Integration tests definition. These are integration tests for several things: 1. that violation is active and enabled 2. that violation is raised for the bad code 3. that line number where violation is raised is correct 4. that `noqa` works Docs: ...
len(all_controlled_violations)
375
4
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/test_visitors/test_ast/test_complexity/test_annotation_complexity/test_annotation_complexity_nesting.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_annotation_complexity/test_annotation_complexity_nesting.py
96
4
assert_*
test_complex_annotations
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooComplexAnnotationViolation, ) from wemake_python_styleguide.visitors.ast.complexity.annotations import ( AnnotationComplexityVisitor, ) annassign_template = 'some: {0}' function_arg_template = """ def some(...
[TooComplexAnnotationViolation])
added
7c3d1c364df422f27ba8fd7d8fd7654626eac1ae4bcf115ddd63dfb43bad493f
assert_*|test_complex_annotations|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooComplexAnnotationViolation, ) from wemake_python_styleguide.visitors.ast.complexity.annotations import ( AnnotationComplexityVisitor, ) annassign_template = 'some: {0}' function_arg_te...
null
null
null
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/test_visitors/test_ast/test_complexity/test_annotation_complexity/test_annotation_complexity_nesting.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_annotation_complexity/test_annotation_complexity_nesting.py
125
4
assert_*
test_complex_annotations_config
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooComplexAnnotationViolation, ) from wemake_python_styleguide.visitors.ast.complexity.annotations import ( AnnotationComplexityVisitor, ) annassign_template = 'some: {0}' function_arg_template = """ def some(...
[TooComplexAnnotationViolation])
added
db0b4a574a4557001cda494f3c7647068fba2f3721b202d0a2af7fb369ed8d71
assert_*|test_complex_annotations_config|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooComplexAnnotationViolation, ) from wemake_python_styleguide.visitors.ast.complexity.annotations import ( AnnotationComplexityVisitor, ) annassign_template = 'some: {0}' function...
null
null
null
wemake-services/wemake-python-styleguide
train
397
4dea0fde0f4cb2dd6297cbf6e0d66d5c8e669d3c
train
tests/test_visitors/test_ast/test_functions/test_positional_only.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_functions/test_positional_only.py
101
4
assert_*
test_posonyargs
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( PositionalOnlyArgumentsViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( PositionalOnlyArgumentsVisitor, ) # Correct: corr...
[PositionalOnlyArgumentsViolation])
modified
ce32e16d24b595ff53ab30f6a0963552e3a53cc7f390f71ce7c86624b8de9c8f
assert_*|test_posonyargs|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.compat.constants import PY38 from wemake_python_styleguide.violations.best_practices import ( PositionalOnlyArgumentsViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( PositionalOnlyArgumentsVisitor, ) #...
[PositionalOnlyArgumentsViolation])
99
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_counts/test_method_counts.py
val
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_counts/test_method_counts.py
148
4
assert_*
test_method_counts_violation
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.ast.complexity.counts import ( MethodMembersVisitor, TooManyMethodsViolation, ) module_without_methods = """ def first(): ... def second(): ... """ module_with_async_functions = """ async def first(): ... async def second(): ... ...
option_values.max_methods)
modified
a17bc61b17f28c260afb7a711ae80eb6c994483a15c86f49f3e5360370fc010f
assert_*|test_method_counts_violation|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.ast.complexity.counts import ( MethodMembersVisitor, TooManyMethodsViolation, ) module_without_methods = """ def first(): ... def second(): ... """ module_with_async_functions = """ async def first(): ... ...
'2')
148
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_counts/test_try_body_length.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_counts/test_try_body_length.py
97
4
assert_*
test_try_body_count_default
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooLongTryBodyViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( TryExceptVisitor, ) try_without_except = """ try: {0} finally: ... """ simple_try_except = """ try: ...
[TooLongTryBodyViolation])
modified
3fc1bd4b3bd78d638af9a12248c920675618428a5ca356f74509bfedeb85e820
assert_*|test_try_body_count_default|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooLongTryBodyViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( TryExceptVisitor, ) try_without_except = """ try: {0} finally: ... """ simple_try_excep...
[TooLongTryBodyViolation])
96
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_counts/test_try_except.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_counts/test_try_except.py
74
4
assert_*
test_try_except_count_default
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooManyExceptCasesViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( TryExceptVisitor, ) try_without_except = """ try: ... finally: ... """ simple_try_except = """ try: ...
[TooManyExceptCasesViolation])
modified
0e91e272a217e475c4277232d2b63559001c567e583515b84cdb7b74541bed2f
assert_*|test_try_except_count_default|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooManyExceptCasesViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( TryExceptVisitor, ) try_without_except = """ try: ... finally: ... """ simple_try...
[TooManyExceptCasesViolation])
73
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_counts/test_yield_length.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_counts/test_yield_length.py
70
4
assert_*
test_yield_length_violation
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAX_LEN_YIELD_TUPLE from wemake_python_styleguide.violations.complexity import ( TooLongYieldTupleViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( YieldTupleVisitor, ) generator = """ def fu...
MAX_LEN_YIELD_TUPLE)
modified
af29f9825747615748d9e295603c5759a32c5be2eea94d18847d997103f60153
assert_*|test_yield_length_violation|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAX_LEN_YIELD_TUPLE from wemake_python_styleguide.violations.complexity import ( TooLongYieldTupleViolation, ) from wemake_python_styleguide.visitors.ast.complexity.counts import ( YieldTupleVisitor...
6)
67
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_function/test_arguments_lambda.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_function/test_arguments_lambda.py
87
4
assert_*
test_no_arguments_error
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.ast.complexity.function import ( FunctionComplexityVisitor, TooManyArgumentsViolation, ) lambda_without_arguments = 'lambda: ...' lambda_with_single_argument = 'lambda arg1: ...' lambda_with_default_argument = 'lambda arg1=None: ......
option_values.max_arguments)
modified
1e8aa91ffd19a28070fe228c0d7c8064bbcd39e046bcf32060e17db95d537422
assert_*|test_no_arguments_error|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.ast.complexity.function import ( FunctionComplexityVisitor, TooManyArgumentsViolation, ) lambda_without_arguments = 'lambda: ...' lambda_with_single_argument = 'lambda arg1: ...' lambda_with_default_argument = ...
'1')
87
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_function/test_asserts_count.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_function/test_asserts_count.py
68
4
assert_*
test_asserts_wrong_count
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooManyAssertsViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( FunctionComplexityVisitor, ) function_without_asserts = 'def function(): ...' function_with_asserts = """ def ...
option_values.max_asserts)
modified
1b01fa88e34d9de0c1165818a3b78fc6b9c8447e48c441250ffac60624896c92
assert_*|test_asserts_wrong_count|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( TooManyAssertsViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( FunctionComplexityVisitor, ) function_without_asserts = 'def function(): ...' function_w...
'2')
68
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_average.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_function/test_cognitive/test_cognitive_average.py
89
4
assert_*
test_complex_cognitive_options
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_function = """ def literal_e...
[CognitiveModuleComplexityViolation])
modified
e4ecc292113e6368b0a24f904888d719214c2673e8eaf7cadcf6538863905a9f
assert_*|test_complex_cognitive_options|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( CognitiveComplexityViolation, CognitiveModuleComplexityViolation, ) from wemake_python_styleguide.visitors.ast.complexity.function import ( CognitiveComplexityVisitor, ) complex_fun...
[CognitiveModuleComplexityViolation])
91
4
wemake-services/wemake-python-styleguide
train
398
edfabfc6f5f680433bf2d0257d58a3c24fbeb26b
train
tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_string.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_string.py
141
4
assert_*
test_string_overuse
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedStringViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( StringOveruseVisitor, ) string_actions = """ first = {0} second({0}) third[{0}] 'new' + {0} """ string_functio...
default_options.max_string_usages)
modified
9345611f2f9e708b92ec7ef4228abc7128c6bb2bc6a562860aced94c527d4f2b
assert_*|test_string_overuse|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedStringViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( StringOveruseVisitor, ) string_actions = """ first = {0} second({0}) third[{0}] 'new' + {0} "...
string_value.replace('"', '') or "''")
141
4