

def test_req_file_parse_comment_end_of_line_with_url(self, tmpdir, finder):
    '\n        Test parsing comments in a requirements file\n        '
    with open(tmpdir.join('req1.txt'), 'w') as fp:
        fp.write('https://example.com/foo.tar.gz # Comment ')
    reqs = list(parse_requirements(tmpdir.join('req1.txt'), finder, session=PipSession()))
    assert (len(fp) == 1)
    assert (reqs[0].link.url == 'https://example.com/foo.tar.gz')

dataset/ETHPy150Open pypa/pip/tests/unit/test_req_file.py TestParseRequirements.test_req_file_parse_comment_end_of_line_with_url/VarMisuse@68/130 `reqs`->`fp`