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
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/fixtures/external_plugins.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/external_plugins.py
52
16
assert
#!/usr/bin/env perl from sys import * import sys from typing import List, Union, Dict int = 12 ++int extra_parens = list((node for node in 'abc')) some_tuple = (1, 2, ) breaking_pycodestyle=3 # commented: str = 'comment' def camelCase(): ... '{}'.format(1) "" '%s' % 'test' assert True ipdb.set_trace() logger.inf...
second
added
7019e85618c6672d2a99fa285363da09a349c8122de338092a5f137c5c2453d5
assert||#!/usr/bin/env perl from sys import * import sys from typing import List, Union, Dict int = 12 ++int extra_parens = list((node for node in 'abc')) some_tuple = (1, 2, ) breaking_pycodestyle=3 # commented: str = 'comment' def camelCase(): ... '{}'.format(1) "" '%s' % 'test' assert True ipdb.set_trace() logger.in...
null
null
null
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/test_checker/test_exception_handling.py
train
wemake-services/wemake-python-styleguide:tests/test_checker/test_exception_handling.py
28
4
assert
test_exception_handling
# -*- coding: utf-8 -*- import ast from contextlib import suppress from wemake_python_styleguide.checker import Checker from wemake_python_styleguide.visitors.base import BaseNodeVisitor class _BrokenVisitor(BaseNodeVisitor): def visit(self, _tree) -> None: raise ValueError('Message from visitor') def...
captured.out
added
02f883fcdd2e85a47c6d508ce11ab214e9ffed8357b3b0ad1c67b3d56c83f2d8
assert|test_exception_handling|# -*- coding: utf-8 -*- import ast from contextlib import suppress from wemake_python_styleguide.checker import Checker from wemake_python_styleguide.visitors.base import BaseNodeVisitor class _BrokenVisitor(BaseNodeVisitor): def visit(self, _tree) -> None: raise ValueError('Message from ...
null
null
null
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/test_checker/test_presets.py
train
wemake-services/wemake-python-styleguide:tests/test_checker/test_presets.py
75
4
assert
test_all_visitors_contained_in_checker
# -*- coding: utf-8 -*- import importlib import inspect from importlib.machinery import SourceFileLoader from operator import itemgetter from pathlib import Path import pytest from wemake_python_styleguide.checker import Checker from wemake_python_styleguide.visitors.base import ( BaseFilenameVisitor, BaseNo...
len(checker_visitors)
modified
90967f16d079e060594777807333649483ac5a7474d1593e24833ffafae4a067
assert|test_all_visitors_contained_in_checker|# -*- coding: utf-8 -*- import importlib import inspect from importlib.machinery import SourceFileLoader from operator import itemgetter from pathlib import Path import pytest from wemake_python_styleguide.checker import Checker from wemake_python_styleguide.visitors.base i...
len(checker_visitors)
72
4
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
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
a897b4b33e03ace20a0684378e4eff17c36d271dd8509536a6cdeed97bcbf644
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
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/test_visitors/test_ast/test_complexity/test_nested/test_nested_classes.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_nested/test_nested_classes.py
126
4
assert_*
test_nested_class
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NestedClassViolation, ) from wemake_python_styleguide.visitors.ast.complexity.nested import ( NESTED_CLASSES_WHITELIST, NestedComplexityVisitor, ) nested_class_in_class = """ class Parent(object): c...
nested_name)
added
5e156e8675edeea23e2f97ae2974adddd675f17a394f6409055331e82e3b8725
assert_*|test_nested_class|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NestedClassViolation, ) from wemake_python_styleguide.visitors.ast.complexity.nested import ( NESTED_CLASSES_WHITELIST, NestedComplexityVisitor, ) nested_class_in_class = """ class Parent(ob...
null
null
null
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/test_visitors/test_ast/test_complexity/test_nested/test_nested_functions.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_nested/test_nested_functions.py
299
4
assert_*
test_lambda_nested_lambdas
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NestedFunctionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.nested import ( NESTED_FUNCTIONS_WHITELIST, NestedComplexityVisitor, ) # Functions: nested_function_in_function = """ de...
[NestedFunctionViolation])
added
efaa78518677e269bfee2413570150c62de3299a978c5d8fca32f09998d36ddf
assert_*|test_lambda_nested_lambdas|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NestedFunctionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.nested import ( NESTED_FUNCTIONS_WHITELIST, NestedComplexityVisitor, ) # Functions: nested_function_...
null
null
null
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
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
31
9
pytest.raises
test_raises_for_existing_alias
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicates.""" with pytest.raises(ValueError): alias('name', ('duplicate', 'duplicate')) def test_useless_alias()...
AttributeError)
added
3619541731912f2622e86bedcb7229307e5b1e78ba69a03b91330df93ce997f6
pytest.raises|test_raises_for_existing_alias|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.visitors.decorators import alias def test_raises_for_duplicates(): """Ensures that decorator raises an exception for duplicates.""" with pytest.raises(ValueError): alias('name', ('duplicate', 'duplicate')) d...
null
null
null
wemake-services/wemake-python-styleguide
train
241
009f798b82fa275f2eda8c7d85815467164210e7
train
tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_partial_floats.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_partial_floats.py
86
4
assert_*
test_double_incorrect_float
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( NumberWithMeaninglessZeroViolation, PartialFloatViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('primitive', [ '10....
[ PartialFloatViolation, NumberWithMeaninglessZeroViolation, ])
modified
dddb73f9f40c7baad9f5979e4bfc7414ac04b8f1d4483a587bf1cf19d05ec21a
assert_*|test_double_incorrect_float|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( NumberWithMeaninglessZeroViolation, PartialFloatViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('p...
[ PartialFloatViolation, NumberWithMeaninglessZeroViolation, ])
87
4
wemake-services/wemake-python-styleguide
train
242
b6b273828a8aae20eb1272f8841a4cb904f6def0
train
tests/test_visitors/test_ast/test_builtins/test_assign/test_unpacking_rules.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_assign/test_unpacking_rules.py
167
4
assert_*
test_multiple_assignments
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( WrongUnpackingViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongAssignmentVisitor, ) single_assignment = '{0} = 1' tuple_assignment1 = 'first, {0} = (1, 2)' tuple_assignment1 =...
[WrongUnpackingViolation])
added
55980f6710f0a7f87a021697a864a032d08950da9b2e72a499e52476bdd0f3b8
assert_*|test_multiple_assignments|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( WrongUnpackingViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongAssignmentVisitor, ) single_assignment = '{0} = 1' tuple_assignment1 = 'first, {0} = (1, ...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
195
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
050999f87b7f92a6633d3f6c4f8282b3700465eb959ccee9f80015850edb70fa
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
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_attributes/test_magic_attributes.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_attributes/test_magic_attributes.py
141
4
assert_*
test_magic_attribute_is_restricted
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import ( DirectMagicAttributeAccessViolation, ) from wemake_python_styleguide.visitors.ast.attributes import ( WrongAttributeVisitor, ) # Wrong: magic_attribute_assigned = 'some.{0} = 1' magic_attribute_accessed = 'print(some...
attribute)
added
7e345361dad41e7fdc955c0748c8551479beda3839de59ea4fc220d2f80127e7
assert_*|test_magic_attribute_is_restricted|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import ( DirectMagicAttributeAccessViolation, ) from wemake_python_styleguide.visitors.ast.attributes import ( WrongAttributeVisitor, ) # Wrong: magic_attribute_assigned = 'some.{0} = 1' magic_...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_blocks/test_class_block.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_class_block.py
57
4
assert_*
test_class_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Classes: class_def1 = 'class {0}():' class_def2 = 'class {0}(object):' class_def3 = 'class {0}:'...
[BlockAndLocalOverlapViolation])
added
b21b710693b02fce05209a817654b7561ec6f24a760b2f65da6754b7239cfa37
assert_*|test_class_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Classes: class_def1 = 'class {0}():' class_def2 = 'class {0}(object):'...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_blocks/test_function_block.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_function_block.py
81
4
assert_*
test_function_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Functions: function_def1 = 'def {0}():' # Wrong usages: function_template1 = """ {0} ... ...
variable_name)
added
46de28061141754971ef121767dc018c02fc64224bc5db4da02038f1bca875e9
assert_*|test_function_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Functions: function_def1 = 'def {0}():' # Wrong usages: function_te...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_blocks/test_import_block.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_import_block.py
72
4
assert_*
test_import_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Imports: import_block = 'import {0}' import_block_as = 'import some as {0}' from_import_block = ...
variable_name)
added
d797ebd2f80fc1fdf0242cb864509c8e65252cf60e3c83f80dfd20a833363801
assert_*|test_import_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Imports: import_block = 'import {0}' import_block_as = 'import some a...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_blocks/test_try_block.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_try_block.py
133
4
assert_*
test_except_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Exception handling: except_block1 = 'except Exception as {0}:' except_block2 = 'except (TypeErro...
variable_name)
added
537547c0ce64b83ea4d654b6ef04730ad72eb303547fc724826fc3240ba3d496
assert_*|test_except_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Exception handling: except_block1 = 'except Exception as {0}:' except...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_blocks/test_with_block.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_with_block.py
86
4
assert_*
test_with_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Context managers: with1 = 'with open() as {0}:' with2 = 'with open() as ({0}, second):' with3 = ...
[BlockAndLocalOverlapViolation])
added
3ebaea02c81e0ea8ad801ad3c4378954cde69ce7b2be3ca4407307e244fbc3eb
assert_*|test_with_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Context managers: with1 = 'with open() as {0}:' with2 = 'with open() as...
null
null
null
wemake-services/wemake-python-styleguide
train
243
b43e738c4527219f03c2eec420fe2e20cfd4c8cc
train
tests/test_visitors/test_ast/test_loops/test_comprehensions/test_variable_definition_comprehensions.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_comprehensions/test_variable_definition_comprehensions.py
60
4
assert_*
test_wrong_definitions_in_comprehension
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( LoopVariableDefinitionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongLoopDefinitionVisitor, ) list_comprehension = """ def container(): nodes = [0 for {0} in some] """ gene...
[LoopVariableDefinitionViolation])
added
77c24768f4b428a0ad698ae79355f68952ff9a53248fe3356cebab6b51471229
assert_*|test_wrong_definitions_in_comprehension|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( LoopVariableDefinitionViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongLoopDefinitionVisitor, ) list_comprehension = """ def container(): nod...
null
null
null
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/fixtures/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa.py
208
0
assert
# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ...
octal_number
modified
19862a789556c4d066a3ee9041840e4be577fdfa64fecb3bfaf3bc5565dbc6c1
assert||# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ful...
octal_number
208
0
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/fixtures/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa.py
219
0
assert
# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ...
hex_number
modified
b6bfa5366488105ba06598b031bbba38402ff31b019e9e2028ee2411161fa54e
assert||# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ful...
hex_number
219
0
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/test_violations/test_docs.py
train
wemake-services/wemake-python-styleguide:tests/test_violations/test_docs.py
39
16
assert
test_configuration
# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: ...
violation.__doc__
modified
354fb699f95f853c16900cc2654306c5e0a1c227fc5776e484af395ffa8f1b36
assert|test_configuration|# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: # Onc...
violation.__doc__
38
16
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/test_violations/test_docs.py
train
wemake-services/wemake-python-styleguide:tests/test_violations/test_docs.py
40
16
assert
test_configuration
# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: ...
violation.__doc__
modified
cd5787fc7f2e0683360af0b3bed34c46a2e6beaec012912e1e509910eff6a905
assert|test_configuration|# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: # Onc...
violation.__doc__
39
16
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/test_violations/test_docs.py
train
wemake-services/wemake-python-styleguide:tests/test_violations/test_docs.py
43
8
assert
test_configuration
# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: ...
is_listed
added
a0f170b229cf7d783d353fc85e2cdb094c5db19b98d510adf7912ccf5b96850d
assert|test_configuration|# -*- coding: utf-8 -*- from wemake_python_styleguide.options.config import Configuration def test_all_violations_are_documented(all_module_violations): """Ensures that all violations are documented.""" for module, classes in all_module_violations.items(): for violation_class in classes: # Onc...
null
null
null
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/test_visitors/test_ast/test_blocks/test_blocks_overlap.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_blocks_overlap.py
75
4
assert_*
test_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor import_and_class1 = """ import overlap class overlap: ... """ import_and_class2 = """ class overl...
[BlockAndLocalOverlapViolation])
added
01b983d0b0047852f625cafe9cbdf9a7d0f944292ce2e5287afa0885062f6c06
assert_*|test_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor import_and_class1 = """ import overlap class overlap: ... """ import_and_class...
null
null
null
wemake-services/wemake-python-styleguide
train
244
fb7bb208e24fd08934e0922cda7646850e0607ee
train
tests/test_visitors/test_ast/test_blocks/test_blocks_overlap.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_blocks_overlap.py
76
4
assert_*
test_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor import_and_class1 = """ import overlap class overlap: ... """ import_and_class2 = """ class overl...
'overlap')
added
2b5e8e3f9ddeb75a96a0d00fd4201aac0a32ba2e457ed460949a018fb6ae5e10
assert_*|test_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor import_and_class1 = """ import overlap class overlap: ... """ import_and_class...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
44
4
assert_*
test_naming_length_settings
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_op...
[TooShortNameViolation])
added
913d933592faf3787ea1c6a178e889a930d2393ae109975cbcf887fcc2708a28
assert_*|test_naming_length_settings|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_templat...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_unicode.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_unicode.py
30
4
assert_*
test_wrong_unicode
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import UnicodeNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'тестовое_имя', 'test_имя2', 'сос', # written with identical to ASCII russ...
[UnicodeNameViolation])
modified
f3e9f9bfee68bc46f36acf4cd5343b6b9de37cf1c406682713c3c28f0ed6a33d
assert_*|test_wrong_unicode|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.naming import UnicodeNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ 'тестовое_имя', 'test_имя2', 'сос', # written with identical to...
[UnicodeNameViolation])
31
4
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
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
33
4
assert_*
test_wrong_variable_name
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import VARIABLE_NAMES_BLACKLIST from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.parametrize('wrong_name', [ ...
wrong_name)
added
15a47b8ce58fd348e22db5659bd0b91de423411d78e7c9fc3c7a8b805a49ae40
assert_*|test_wrong_variable_name|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import VARIABLE_NAMES_BLACKLIST from wemake_python_styleguide.violations.naming import ( WrongVariableNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor @pytest.mark.pa...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_ast/test_naming/test_reserved_argument.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_reserved_argument.py
67
4
assert_*
test_reserved_argument_name
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import SPECIAL_ARGUMENT_NAMES_WHITELIST from wemake_python_styleguide.violations.naming import ( ReservedArgumentNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor # Correct: correct_method_temp...
[ReservedArgumentNameViolation])
added
326c4b7b5894cef69f7c836e45e2dea32798f4d3746bd0ff5fb8d3515b43341e
assert_*|test_reserved_argument_name|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import SPECIAL_ARGUMENT_NAMES_WHITELIST from wemake_python_styleguide.violations.naming import ( ReservedArgumentNameViolation, ) from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor #...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
200
4
assert_*
test_self_variable_reassignment_triple
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test_variable = 5 test_variable = 10 """...
[ ReassigningVariableToItselfViolation, ReassigningVariableToItselfViolation, ReassigningVariableToItselfViolation, ])
added
b388942ec698249eb34bdbfe6ec2b0f567a41fd8ba34c58254387a0fd07d14a5
assert_*|test_self_variable_reassignment_triple|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_number_meaningless_zeros.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_number_meaningless_zeros.py
47
4
assert_*
test_meaningless_zeros
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, NumberWithMeaninglessZeroViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('number', [ '0.1...
number.lstrip('-').lstrip('+'))
added
8679807e617a7c6278ad33831f16acc5a565c22f4315ac1e6df7d7384f62c8b9
assert_*|test_meaningless_zeros|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, NumberWithMeaninglessZeroViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('num...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_positive_exponent.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_positive_exponent.py
40
4
assert_*
test_positive_exponent
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, NumberWithMeaninglessZeroViolation, PositiveExponentViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.p...
[PositiveExponentViolation])
added
df5e44625537ff1c1190c8a1c1ded0e3c0e456b628ada35e542a7f3b0208139a
assert_*|test_positive_exponent|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, NumberWithMeaninglessZeroViolation, PositiveExponentViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @p...
null
null
null
wemake-services/wemake-python-styleguide
train
245
7eae7ecc11666b0a3e8d43f43a80b06d40c4e6e8
train
tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_wrong_hex_case.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_wrong_hex_case.py
39
4
assert_*
test_hex_wrong_case
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, WrongHexNumberCaseViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) hex_number_templates = [ '0x{0}', '0xA{0}', ...
[WrongHexNumberCaseViolation])
added
00e5e6b048cfae1a05a6a2aa7daf3cf575c2057c83023d73c178653bcebb659a
assert_*|test_hex_wrong_case|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadNumberSuffixViolation, WrongHexNumberCaseViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) hex_number_templates = [ '0x{0}', '0xA{...
null
null
null
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
84
4
assert_*
test_incorrect_slots
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = """ class ClassWithSlo...
[WrongSlotsViolation])
added
065b4ab712d522ea5e4c7135331d4e1c2741ec721846f96a72e9f62bbc7a572b
assert_*|test_incorrect_slots|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = ...
null
null
null
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
23
4
assert_*
test_short_variable_name
# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_options, mode...
short_name)
modified
2ea5b803cad4f2cd9b219faf43548cc01ff4cc400f688018b62ced86293ac65f
assert_*|test_short_variable_name|# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_option...
short_name)
25
4
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
42
4
assert_*
test_naming_length_settings
# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_options, mode...
[TooShortNameViolation])
modified
57faa47daa17b0a37eac92c865ec16b614d65422e27bd949aafc47d646eb2fbb
assert_*|test_naming_length_settings|# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_opt...
[TooShortNameViolation])
44
4
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_naming_rules/test_short.py
43
4
assert_*
test_naming_length_settings
# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_options, mode...
short_name)
modified
47634ed21879208719b39f588eb31c05dc85cd531c8e8b77719c4f8d79e7479b
assert_*|test_naming_length_settings|# -*- coding: utf-8 -*- from wemake_python_styleguide.violations.naming import TooShortNameViolation from wemake_python_styleguide.visitors.ast.naming import WrongNameVisitor def test_short_variable_name( assert_errors, assert_error_text, parse_ast_tree, naming_template, default_opt...
short_name)
45
4
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
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
31
4
assert_*
test_wrong_variable_name
# -*- 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
1033d52102898fd714f22c548584fff5407fbb5caafddf65c974191912a0ea26
assert_*|test_wrong_variable_name|# -*- 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_varia...
[WrongVariableNameViolation])
32
4
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
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
32
4
assert_*
test_wrong_variable_name
# -*- 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( ...
wrong_name)
modified
a1377ccc75f955fb9bce918e6564bb3db36610769b755dda9ed1c43c767bdab0
assert_*|test_wrong_variable_name|# -*- 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_varia...
wrong_name)
33
4
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
164
4
assert_*
test_self_variable_reassignment
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test_variable = 5 test_variable = 10 """...
[ReassigningVariableToItselfViolation])
added
5a18e1212658427a21de88dfb32162c73f17cbfe194ce375d558a15c61b89a3f
assert_*|test_self_variable_reassignment|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test_variab...
null
null
null
wemake-services/wemake-python-styleguide
train
246
e71e37f556088a32079c1727694307549b6513b5
train
tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_naming/test_variable_self_reassignment.py
205
4
assert_*
test_self_variable_reassignment_triple
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test_variable = 5 test_variable = 10 """...
[ ReassigningVariableToItselfViolation, ReassigningVariableToItselfViolation, ReassigningVariableToItselfViolation, ])
added
3f80b72a34f6a895cdb4f625b4fecf026440322ff17b10a9cf820ae945df88ca
assert_*|test_self_variable_reassignment_triple|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ReassigningVariableToItselfViolation, ) from wemake_python_styleguide.visitors.ast.naming import ( WrongVariableAssignmentVisitor, ) # Correct: right_fragment = """ test...
null
null
null
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
192
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
8e58e36c9ade5826449ff338cf616fb040cf18eb07f1b553525626eab0cd9b6d
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
191
8
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
195
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
6eeb41a2ce6868eed0712ecd256a5ab2b7baf308cddd040e10723c69eab4bb9f
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
194
8
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
196
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
6c18806437c21ae5eda2c5e124a4d78d54c9b6c22a404d9fe5938e9bb695c04e
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)
195
8
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
224
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
f2816f36a299d2a9e3b425162e5ca527668879f933b2d90311d99bbad86e97ff
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)
223
4
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_visitors/test_ast/test_blocks/test_control_variables.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_control_variables.py
203
4
assert_*
test_control_variable_used_after_block
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ControlVarUsedAfterBlockViolation, ) from wemake_python_styleguide.visitors.ast.blocks import ( AfterBlockVariablesVisitor, ) # Correct: correct_for_loop1 = """ def wrapper(): for i, j in (): p...
[ControlVarUsedAfterBlockViolation])
added
fd23cb523545c1c027018bae0335e7e0e88dd577e187a66178acc2dbfbd18b38
assert_*|test_control_variable_used_after_block|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ControlVarUsedAfterBlockViolation, ) from wemake_python_styleguide.visitors.ast.blocks import ( AfterBlockVariablesVisitor, ) # Correct: correct_for_loop1 = """ def wrap...
null
null
null
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_visitors/test_ast/test_blocks/test_overlap/test_blocks_overlap.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_overlap/test_blocks_overlap.py
98
4
assert_*
test_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Wrong: import_and_class1 = """ import overlap class overlap: ... """ import_and_class2 = """ c...
[BlockAndLocalOverlapViolation])
added
47936f009ec2b42b4b5a376ce5cd2391400b855a8801f3d01219657b92818b36
assert_*|test_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Wrong: import_and_class1 = """ import overlap class overlap: ... """ import_...
null
null
null
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_visitors/test_ast/test_blocks/test_overlap/test_blocks_overlap.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_blocks/test_overlap/test_blocks_overlap.py
99
4
assert_*
test_block_overlap
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Wrong: import_and_class1 = """ import overlap class overlap: ... """ import_and_class2 = """ c...
'overlap')
added
8f93b4ac3dbf445339a27d6f397196a760ed738a0a494d5746117744e58a2951
assert_*|test_block_overlap|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( BlockAndLocalOverlapViolation, ) from wemake_python_styleguide.visitors.ast.blocks import BlockVariableVisitor # Wrong: import_and_class1 = """ import overlap class overlap: ... """ import_...
null
null
null
wemake-services/wemake-python-styleguide
train
247
77d84f84f99f63bd32229dfe57d6ad5bd268741a
train
tests/test_visitors/test_ast/test_loops/test_loops/test_iter_type.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_loops/test_loops/test_iter_type.py
90
4
assert_*
test_iter_incorrect_type
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( WrongLoopIterTypeViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongLoopDefinitionVisitor, ) for_loop_template = """ def function(): for index in {0}: ... """ list_compreh...
[WrongLoopIterTypeViolation])
added
97f4e158a8515e5ebfaf561cb6df97dbdf3ebc118965f7d29e70b3a9abe7a7fe
assert_*|test_iter_incorrect_type|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( WrongLoopIterTypeViolation, ) from wemake_python_styleguide.visitors.ast.loops import ( WrongLoopDefinitionVisitor, ) for_loop_template = """ def function(): for index in {0}: ... """ li...
null
null
null
wemake-services/wemake-python-styleguide
train
248
6fb5128f7c7aa73f97ca31f0123f710fe9e25f4c
train
tests/test_visitors/test_ast/test_builtins/test_set_elements.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_set_elements.py
114
4
assert_*
test_set_with_pure_duplicate
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInSetViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' @pytest.mark.parametrize('code', [ set_lite...
[NonUniqueItemsInSetViolation])
added
5a5e1e2b653977d814ea738613ba4b81a36eb293d7b1d0059914698848126c99
assert_*|test_set_with_pure_duplicate|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInSetViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' @pytest.mark.parametri...
null
null
null
wemake-services/wemake-python-styleguide
train
248
6fb5128f7c7aa73f97ca31f0123f710fe9e25f4c
train
tests/test_visitors/test_ast/test_builtins/test_set_elements.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_set_elements.py
142
4
assert_*
test_set_with_similar_values
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInSetViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' @pytest.mark.parametrize('code', [ set_lite...
[NonUniqueItemsInSetViolation])
added
2304a9ed0880dfb64a57b8fa7623e86788d924e1198e4f6236e6f2ef5eeaac7b
assert_*|test_set_with_similar_values|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInSetViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' @pytest.mark.parametri...
null
null
null
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
193
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
440afcbcc7edda770170b3c312e3733a0ac39133147ae9ff3c2adf4de0c8fc14
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
192
8
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
196
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
ca3e59751e12dbc8dcc2f8809bc08d10639a540e9942c5f0bd7bb9e0893842fe
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
195
8
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
197
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
bfab21c0e9e0c275a4fd3e0c34ea8ac2fb87472c5d2442095c0087ee875c362d
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)
196
8
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
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
120
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])
added
84d5432ac6b2366a0440c75ff04b70177ddf9bbb2da5fd5e49796ebcd8fd3fc0
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...
null
null
null
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
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
145
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])
added
8cce502cdada95ac13c69aeefe8564b5676b5e558b5a3825a705296a5fba8bee
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 =...
null
null
null
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
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
174
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])
added
d165342adf38c531042fbfbfb8bd6fcefe24806b62d697aaf3a56ae39702bf8b
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 =...
null
null
null
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
train
tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_hashable.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_hashable.py
57
4
assert_*
test_hash_with_impure
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, UnhashableTypeInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_te...
[UnhashableTypeInHashViolation])
added
3e74eaadf635866093bd3264deeb167b93caae966f79ff323ca1ec11caaca1cc
assert_*|test_hash_with_impure|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, UnhashableTypeInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}...
null
null
null
wemake-services/wemake-python-styleguide
train
249
e126a1ec55410faf5283dcf333348b1fd136897e
train
tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_hashable.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_collection_hashes/test_hash_hashable.py
87
4
assert_*
test_hash_with_impure_duplicates
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, UnhashableTypeInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '{{{0}, {1}}}' nested_set_te...
[ NonUniqueItemsInHashViolation, UnhashableTypeInHashViolation, UnhashableTypeInHashViolation, ])
added
a0e4f3ed42723523306356276553ff4e48a4f14cbfb39d34e34f89f14f21008b
assert_*|test_hash_with_impure_duplicates|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( NonUniqueItemsInHashViolation, UnhashableTypeInHashViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( WrongCollectionVisitor, ) set_literal_template = '...
null
null
null
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
194
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
8e8e8002e7a70ef91636be332d1e3883c23f0630a446de433501b5082627ebcd
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
193
8
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
197
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
2960614f8be54b88cb474b6c4068b4e39b6a9754b29cb4bb1aaa28ffe8e324e8
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
196
8
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
198
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
968d4c28dc434b30d7f699a26b0c1850c8267cce5c6c912f28e6e10a582bebb5
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)
197
8
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
226
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
e8cd8d8b9a9276bc4f70c5366ae5ba00356ee18862ce5b98476e6646609c2b9f
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)
225
4
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
189
4
assert_*
test_magic_number_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
[MagicNumberViolation])
modified
4d38d481fb25ac260633bdda78c509dcce277297302b973ebb035963234d9805
assert_*|test_magic_number_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct...
[MagicNumberViolation])
186
4
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
190
4
assert_*
test_magic_number_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
number.replace('-', ''))
modified
0c4f3cc4726d0269dd9d3dacd10fa062bfcd6515711f2040de402a1c04409ea5
assert_*|test_magic_number_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct...
number.replace('-', ''))
187
4
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_magic_numbers.py
225
4
assert_*
test_magic_number_octal_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
[MagicNumberViolation])
modified
2ac2138ff8beebc247f977b01098e8d0664728ed3536730d8ab673baf3409db9
assert_*|test_magic_number_octal_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # C...
[MagicNumberViolation])
222
4
wemake-services/wemake-python-styleguide
train
250
4567f91611791a4d1a75956acf8cb073cc78d90f
train
tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_complex_suffix.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_tokenize/test_primitives/test_numbers/test_complex_suffix.py
35
4
assert_*
test_bad_complex_suffix
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadComplexNumberSuffixViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('number', [ '1J', '2J + 10', ]) def test_bad_...
[BadComplexNumberSuffixViolation])
added
2de4a7f44b7fe68d9502eb45f184cb9c5ce4d95b375e643a5a584a93b3a62cca
assert_*|test_bad_complex_suffix|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( BadComplexNumberSuffixViolation, ) from wemake_python_styleguide.visitors.tokenize.primitives import ( WrongNumberTokenVisitor, ) @pytest.mark.parametrize('number', [ '1J', '2J + 10', ]) ...
null
null
null
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
196
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
4d32ee4ddbc6f1c3b48a396470ac3a4109860c83a9e7023d15f95d2d3d0b27d5
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
194
8
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
199
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
1c1e12aae54ca5561ae0bed8143f1b9312be4a433fa3474ea43858e99de2bc14
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
197
8
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
200
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
98987e4dbc671668ade18d29a4b31dffe9aa0eb51b61c8debf33b0e802125bfa
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)
198
8
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
228
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
f7589db407598c2e93666931127a6fa509f4f9ddd8256d74e82b56aa948217ab
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)
226
4
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_expressions.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_expressions.py
127
4
assert_*
test_func_expression_overuse
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedExpressionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( ExpressionOveruseVisitor, ) module_context = """ {0} {1} """ function_context1 = """ def function(): {...
[OverusedExpressionViolation])
added
f41ba1f25a4a57b58c48a4d592401a614fed8ea4528f308082542c8571d47a31
assert_*|test_func_expression_overuse|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedExpressionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( ExpressionOveruseVisitor, ) module_context = """ {0} {1} """ function_context1 =...
null
null
null
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
train
tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_expressions.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_complexity/test_overuses/test_overused_expressions.py
148
4
assert_*
test_module_expression_overuse
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedExpressionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( ExpressionOveruseVisitor, ) module_context = """ {0} {1} """ function_context1 = """ def function(): {...
[OverusedExpressionViolation])
added
10a4a6a9bd6f70e5785d440095e1edcaea8366b951584b341e3af4d98592f33c
assert_*|test_module_expression_overuse|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.complexity import ( OverusedExpressionViolation, ) from wemake_python_styleguide.visitors.ast.complexity.overuses import ( ExpressionOveruseVisitor, ) module_context = """ {0} {1} """ function_context1...
null
null
null
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
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
140
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...
[OverusedStringViolation])
added
fa1e7ccca43d269d71e1fb9dcf5e95afb2b8d2b78a8dba8cab440dc9f18afa9b
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} "...
null
null
null
wemake-services/wemake-python-styleguide
train
251
ed1afeb3366525f0b3f1adc346a189a3c0f3b923
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...
string_value.replace('"', '') or "''")
added
3d4711cde8d5ae0e7fc10b12668236d1782afdda4f366b6ac2c9baa402eaf078
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} "...
null
null
null
wemake-services/wemake-python-styleguide
train
252
c4bdc28439470c51485e7f92a88b69d82731d3b9
train
tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
87
4
assert_*
test_incorrect_slots
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = """ class ClassWithSlo...
[WrongSlotsViolation])
modified
e32a0757c541cd073ab003581273169112783175dd58f334334e84ea1175c7a1
assert_*|test_incorrect_slots|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = ...
[WrongSlotsViolation])
84
4
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
197
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
3d5cc1966abd5661e1028e9fe7f4f3190fb39d5f1965800116f35e0548d44842
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
196
8
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
200
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
93b26f4741627226da549b719fb22ca6564e843cd8e51250ae7ab67fbe8d0c82
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
199
8
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
201
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
943f8abbda0b8a80838813cd9cfa8743e4c99496f113d56c37d677add5ba1474
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)
200
8
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
229
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
56b4e424c3d3215812e3410e2fdade7fd560056c3c23201a90af01c1de9dcd84
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)
228
4
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
190
4
assert_*
test_magic_number_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
[MagicNumberViolation])
modified
b8777a7f827e5b99e3a72d155717cf7ab9eef271d9664d774244c0bdcc6a632c
assert_*|test_magic_number_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct...
[MagicNumberViolation])
189
4
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
191
4
assert_*
test_magic_number_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
number.replace('-', ''))
modified
6af6e3d0da03b890076b1e05923f70e730c1aea2f631dfbd744793dbd6238cd3
assert_*|test_magic_number_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct...
number.replace('-', ''))
190
4
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_magic_numbers.py
226
4
assert_*
test_magic_number_octal_warning
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # Correct usages: assignment = 'cons...
[MagicNumberViolation])
modified
57bc550db1b318a7426ef8624ddd079b12076779650b7c18d89c4c0b66b43d12
assert_*|test_magic_number_octal_warning|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.constants import MAGIC_NUMBERS_WHITELIST from wemake_python_styleguide.violations.best_practices import ( MagicNumberViolation, ) from wemake_python_styleguide.visitors.ast.builtins import MagicNumberVisitor # C...
[MagicNumberViolation])
225
4
wemake-services/wemake-python-styleguide
train
253
edb5d8f9929ef5e16e4c4c1e9f2deebc06a18155
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_zero_division.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_zero_division.py
57
4
assert_*
test_zero_div
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest.mark.parametrize('expression', [ '/= 0', '/= 0...
[ZeroDivisionViolation])
added
38f3563fe7401d38fff1ed38bdd020165ed25901e5a4e1131f705fbe6857bd74
assert_*|test_zero_div|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest.mark.parametrize('expression', [ '/= 0', '/=...
null
null
null
wemake-services/wemake-python-styleguide
train
254
133aa33b6a22dd0b9ea637f1ce067a7d3c1a33f4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
198
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
58a22530b4300648ec05eaae40606c2c7d64090f973c52bb9ba559d221155d47
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
197
8
wemake-services/wemake-python-styleguide
train
254
133aa33b6a22dd0b9ea637f1ce067a7d3c1a33f4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
201
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
e6204794b43b0701c5e570216b7cd2426dde36c77cb35da42f23f40e00331aab
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
200
8
wemake-services/wemake-python-styleguide
train
254
133aa33b6a22dd0b9ea637f1ce067a7d3c1a33f4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
202
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
4034e54e4f175632cb2510fcf66a028fce76a9f3378caa59f3677e26563b74a8
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)
201
8
wemake-services/wemake-python-styleguide
train
254
133aa33b6a22dd0b9ea637f1ce067a7d3c1a33f4
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
230
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
b0bf3215aa39392216f23b09d8da52cdc41503de38ba30239d21d414667126e4
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)
229
4
wemake-services/wemake-python-styleguide
train
254
133aa33b6a22dd0b9ea637f1ce067a7d3c1a33f4
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
137
4
assert_*
test_useless_overwriting
# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed = """ class Useless(object): {decorator} def function(self, {args_definition}): ...
[oop.UselessOverwrittenMethodViolation])
added
cebf838ddef78aa29498f3500218f06d1e3888ab00a173ba6d254c9022cf35d3
assert_*|test_useless_overwriting|# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed = """ class Useless(object): {decorator} def function(self,...
null
null
null
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/fixtures/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa.py
208
0
assert
# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ...
octal_number
modified
530bdd9b5dc58696f28f973c0831d82816ce730bb61c6803efe10b375ab4cf3b
assert||# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ful...
octal_number
208
0
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/fixtures/noqa.py
train
wemake-services/wemake-python-styleguide:tests/fixtures/noqa.py
219
0
assert
# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ...
hex_number
modified
12e2ede445b5634612ac3e3d245219c068009ae3c2f0ce225d6ccbdad3c3bd86
assert||# -*- coding: utf-8 -*- """ 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 .version import get_version # noqa: WPS300 ful...
hex_number
219
0
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
199
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
ad1a368ab4a401ab8957ee41e37faa19d94f6a86a692a78dbf893a179d637cbb
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
198
8
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
202
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
9fbe87b808adabe2dc3c6a152a63d7840f1b011a753f7c38e05fdf56e17f644a
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
201
8
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
203
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
02ae839f89857a6ae21b64cb6afca48e6b7f2eab43594f4595bb981b70f18029
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)
202
8
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_checker/test_noqa.py
test
wemake-services/wemake-python-styleguide:tests/test_checker/test_noqa.py
231
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
833eaeff4d2682028738a33d58e7d86de19ea8460e0f44cdc4ae7dd14d0a0520
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)
230
4
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_useless_math.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_useless_math.py
58
4
assert_*
test_zero_div
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( MeaninglessNumberOperationViolation, ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest.mark.parametr...
[ZeroDivisionViolation])
modified
8f939ac5bef305c1930146b671e1e5b4dfebe1daba40306eacb3642a1167c7ed
assert_*|test_zero_div|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( MeaninglessNumberOperationViolation, ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest.mark.pa...
[ZeroDivisionViolation])
57
4
wemake-services/wemake-python-styleguide
train
255
5e338925ee9e86ea3023f784b455b88319b1da44
train
tests/test_visitors/test_ast/test_builtins/test_numbers/test_useless_math.py
test
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_builtins/test_numbers/test_useless_math.py
95
4
assert_*
test_meaningless_math
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( MeaninglessNumberOperationViolation, ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest.mark.parametr...
[MeaninglessNumberOperationViolation])
added
6d0c050b259a388fdeb493a8ea824c97a3f23b2461953d1da2cbf9964283dd80
assert_*|test_meaningless_math|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.consistency import ( MeaninglessNumberOperationViolation, ZeroDivisionViolation, ) from wemake_python_styleguide.visitors.ast.builtins import ( UselessOperatorsVisitor, ) usage_template = 'constant {0}' @pytest...
null
null
null
wemake-services/wemake-python-styleguide
train
256
fae679790f3cda812b76ab9474bd8ef835499b13
train
tests/test_visitors/test_ast/test_classes/test_base_classes/test_expression_base_class.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_classes/test_base_classes/test_expression_base_class.py
42
4
assert_*
test_base_class_expression
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongBaseClassViolation from wemake_python_styleguide.visitors.ast.classes import WrongClassVisitor class_with_base = """ class Meta({0}): '''Docs.''' """ @pytest.mark.parametrize('base', [ '(lambda: object)()', '...
[WrongBaseClassViolation])
added
5c647c4f32ea6a26d7a74ae11d7fa8d96b9a7131deadb9ccc596332f473be7f6
assert_*|test_base_class_expression|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongBaseClassViolation from wemake_python_styleguide.visitors.ast.classes import WrongClassVisitor class_with_base = """ class Meta({0}): '''Docs.''' """ @pytest.mark.parametrize('base', [ '(la...
null
null
null
wemake-services/wemake-python-styleguide
train
256
fae679790f3cda812b76ab9474bd8ef835499b13
train
tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
train
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_classes/test_class_attributes/test_slots_syntax.py
91
4
assert_*
test_incorrect_slots
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = """ class ClassWithSlo...
[WrongSlotsViolation])
added
2257e42538037910385a42a380c2857f0f5e46940760047a19f335fdf957ca57
assert_*|test_incorrect_slots|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.oop import WrongSlotsViolation from wemake_python_styleguide.visitors.ast.classes import WrongSlotsVisitor class_body_template = """ class ClassWithSlots(object): __slots__ = {0} """ class_body_typed_template = ...
null
null
null
wemake-services/wemake-python-styleguide
train
256
fae679790f3cda812b76ab9474bd8ef835499b13
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
137
4
assert_*
test_useless_overwriting
# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed = """ class Useless(object): {decorator} def function(self, {args_definition}): ...
[oop.UselessOverwrittenMethodViolation])
added
833a563deebef43357b75aabe9743473d69be7461b56e553b5c14847bddf373e
assert_*|test_useless_overwriting|# -*- coding: utf-8 -*- from typing import List, NamedTuple import pytest from wemake_python_styleguide.violations import oop from wemake_python_styleguide.visitors.ast.classes import WrongMethodVisitor regular_method_detailed = """ class Useless(object): {decorator} def function(self,...
null
null
null
wemake-services/wemake-python-styleguide
train
256
fae679790f3cda812b76ab9474bd8ef835499b13
train
tests/test_visitors/test_ast/test_functions/test_complex_default_values.py
val
wemake-services/wemake-python-styleguide:tests/test_visitors/test_ast/test_functions/test_complex_default_values.py
47
4
assert_*
test_wrong_function_defaults
# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ComplexDefaultValueViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( FunctionDefinitionVisitor, ) function_with_defaults = """ def function(self, with_default={0}): ... """ @p...
[ComplexDefaultValueViolation])
added
3ec7ce2f9ec12fbe581daaced0f3d21344dd46368ad01a3ae1b9b05f6d6415a2
assert_*|test_wrong_function_defaults|# -*- coding: utf-8 -*- import pytest from wemake_python_styleguide.violations.best_practices import ( ComplexDefaultValueViolation, ) from wemake_python_styleguide.visitors.ast.functions import ( FunctionDefinitionVisitor, ) function_with_defaults = """ def function(self, with_def...
null
null
null