"""Tests for src.notes.""" from src.notes import read_note, write_note def test_write_then_read_round_trip(tmp_path) -> None: path = tmp_path / "note.txt" body = "first line\nsecond line\n" assert write_note(path, body) == len(body) assert read_note(path) == body def test_read_note_of_an_empty_file(tmp_path) -> None: path = tmp_path / "empty.txt" write_note(path, "") assert read_note(path) == ""