def test_xfail_using_platform(self, pytester: Pytester) -> None:
        """Verify that platform can be used with xfail statements."""
        item = pytester.getitem(
            """
            import pytest
            @pytest.mark.xfail("platform.platform() == platform.platform()")
            def test_func():
                assert 0
        """
        )
        reports = runtestprotocol(item, log=False)
        assert len(reports) == 3
        callreport = reports[1]
        assert callreport.wasxfail
Verify that platform can be used with xfail statements.
testing/test_skipping.py