(
location, # type: str
name, # type: str
version, # type: str
)
| 331 | ) |
| 332 | |
| 333 | def write_pkg_info_file( |
| 334 | location, # type: str |
| 335 | name, # type: str |
| 336 | version, # type: str |
| 337 | ): |
| 338 | # type: (...) -> None |
| 339 | with safe_open( |
| 340 | os.path.join( |
| 341 | location, |
| 342 | metadata_dir_name("{name}-{version}".format(name=name, version=version)), |
| 343 | metadata_file_name, |
| 344 | ), |
| 345 | "w", |
| 346 | ) as fp: |
| 347 | print("Metadata-Version: 1.0", file=fp) |
| 348 | print("Name: {name}".format(name=name), file=fp) |
| 349 | print("Version: {version}".format(version=version), file=fp) |
| 350 | |
| 351 | foo_location = os.path.join(str(tmpdir), "foo_location") |
| 352 | touch(os.path.join(foo_location, metadata_dir_name("foo-100"), "bar")) |
no test coverage detected