Repositories / agent-snapshot.git
test_programs/read_non_directory_component.py
Clone (read-only): git clone http://git.guha-anderson.com/git/agent-snapshot.git
import os
from pathlib import Path
root = Path(os.environ["AGENT_SNAPSHOT_TEST_REPO"])
not_directory = root / "not_directory"
not_directory.write_text("not a directory\n")
try:
os.lstat(not_directory / "2851767" / "ns")
except OSError:
pass