9228ad83a3ecde2fb5a714d1eb43c7c1ee2e200b,src/python/pants/backend/python/lint/flake8/rules_integration_test.py,Flake8IntegrationTest,make_target_with_origin,#,37

Before Change


        interpreter_constraints: Optional[str] = None,
        origin: Optional[OriginSpec] = None,
    ) -> PythonTargetAdaptorWithOrigin:
        input_snapshot = self.request_single_product(Snapshot, InputFilesContent(source_files))
        adaptor_kwargs = dict(
            sources=EagerFilesetWithSpec("test", {"globs": []}, snapshot=input_snapshot),
            address=Address.parse("test:target"),
        )
        if interpreter_constraints:
            adaptor_kwargs["compatibility"] = interpreter_constraints
        if origin is None:
            origin = SingleAddress(directory="test", name="target")
        return PythonTargetAdaptorWithOrigin(PythonTargetAdaptor(**adaptor_kwargs), origin)

    def run_flake8(
        self,
        targets: List[PythonTargetAdaptorWithOrigin],

After Change


    ) -> TargetWithOrigin:
        for source_file in source_files:
            self.create_file(source_file.path, source_file.content.decode())
        target = PythonLibrary(
            {PythonInterpreterCompatibility.alias: interpreter_constraints},
            address=Address.parse(":target"),
        )
        if origin is None:
            origin = SingleAddress(directory="test", name="target")
        return TargetWithOrigin(target, origin)

    def run_flake8(
        self,
        targets: List[TargetWithOrigin],
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 25

Instances


Project Name: pantsbuild/pants
Commit Name: 9228ad83a3ecde2fb5a714d1eb43c7c1ee2e200b
Time: 2020-04-15
Author: 14852634+Eric-Arellano@users.noreply.github.com
File Name: src/python/pants/backend/python/lint/flake8/rules_integration_test.py
Class Name: Flake8IntegrationTest
Method Name: make_target_with_origin


Project Name: pantsbuild/pants
Commit Name: 9228ad83a3ecde2fb5a714d1eb43c7c1ee2e200b
Time: 2020-04-15
Author: 14852634+Eric-Arellano@users.noreply.github.com
File Name: src/python/pants/backend/python/lint/pylint/rules_integration_test.py
Class Name: PylintIntegrationTest
Method Name: make_target_with_origin


Project Name: pantsbuild/pants
Commit Name: 9228ad83a3ecde2fb5a714d1eb43c7c1ee2e200b
Time: 2020-04-15
Author: 14852634+Eric-Arellano@users.noreply.github.com
File Name: src/python/pants/backend/python/lint/bandit/rules_integration_test.py
Class Name: BanditIntegrationTest
Method Name: make_target_with_origin