5036877eb6bf18db3f6e6ebe15696b9a1585b667,tests/python/pants_test/backend/python/tasks/test_ctypes_integration.py,CTypesIntegrationTest,test_ctypes_native_language_interop,#CTypesIntegrationTest#,136

Before Change


      orig_wrapped_math_build = read_file(self._wrapped_math_build_file)
      without_strict_deps_wrapped_math_build = re.sub(
        "strict_deps=False,", "", orig_wrapped_math_build)
      safe_file_dump(self._wrapped_math_build_file, without_strict_deps_wrapped_math_build)

      // This should fail because it does not turn on strict_deps for a target which requires it.
      pants_binary_strict_deps_failure = self.run_pants_with_workdir(
        command=["binary", self._binary_target_with_interop],
        // Explicitly set to True (although this is the default).
        config={"native-build-settings": {"strict_deps": True}},
        workdir=os.path.join(buildroot.new_buildroot, ".pants.d"),
        build_root=buildroot.new_buildroot)
      self.assert_failure(pants_binary_strict_deps_failure)
      self.assertIn("fatal error: "some_math.h" file not found",
                    pants_binary_strict_deps_failure.stdout_data)

    pants_run_interop = self.run_pants(["-q", "run", self._binary_target_with_interop], config={
      "native-build-settings": {
        "strict_deps": False,
      },
    })
    self.assert_success(pants_run_interop)
    self.assertEqual("x=3, f(x)=299\n", pants_run_interop.stdout_data)

  def test_ctypes_third_party_integration(self):

After Change


        self.assertIn(modified_result_message, binary_run_output)

  def test_ctypes_native_language_interop(self):
    for variant in ToolchainVariant.allowed_values:
      self._assert_ctypes_interop_with_mock_buildroot(variant)

  _include_not_found_message_for_variant = {
    "gnu": "fatal error: some_math.h: No such file or directory",
    "llvm": "fatal error: "some_math.h" file not found"
  }
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 8

Instances


Project Name: pantsbuild/pants
Commit Name: 5036877eb6bf18db3f6e6ebe15696b9a1585b667
Time: 2018-12-10
Author: 1305167+cosmicexplorer@users.noreply.github.com
File Name: tests/python/pants_test/backend/python/tasks/test_ctypes_integration.py
Class Name: CTypesIntegrationTest
Method Name: test_ctypes_native_language_interop


Project Name: pantsbuild/pants
Commit Name: 5036877eb6bf18db3f6e6ebe15696b9a1585b667
Time: 2018-12-10
Author: 1305167+cosmicexplorer@users.noreply.github.com
File Name: tests/python/pants_test/backend/python/tasks/test_ctypes_integration.py
Class Name: CTypesIntegrationTest
Method Name: test_ctypes_third_party_integration


Project Name: pantsbuild/pants
Commit Name: 5036877eb6bf18db3f6e6ebe15696b9a1585b667
Time: 2018-12-10
Author: 1305167+cosmicexplorer@users.noreply.github.com
File Name: tests/python/pants_test/backend/python/tasks/test_ctypes_integration.py
Class Name: CTypesIntegrationTest
Method Name: test_ctypes_native_language_interop


Project Name: pantsbuild/pants
Commit Name: 5036877eb6bf18db3f6e6ebe15696b9a1585b667
Time: 2018-12-10
Author: 1305167+cosmicexplorer@users.noreply.github.com
File Name: tests/python/pants_test/backend/python/tasks/test_ctypes_integration.py
Class Name: CTypesIntegrationTest
Method Name: test_native_compiler_option_sets_integration