Test tutorial with sequential code blocks. The first-tracking.md tutorial has blocks that depend on each other: 1. Run tracker (creates emissions.csv) 2. Read emissions.csv with pandas 3. Access tracker.final_emissions Use memory=True so blocks can share state.
(tmp_path, monkeypatch)
| 39 | |
| 40 | |
| 41 | def test_first_tracking_tutorial(tmp_path, monkeypatch): |
| 42 | """Test tutorial with sequential code blocks. |
| 43 | |
| 44 | The first-tracking.md tutorial has blocks that depend on each other: |
| 45 | 1. Run tracker (creates emissions.csv) |
| 46 | 2. Read emissions.csv with pandas |
| 47 | 3. Access tracker.final_emissions |
| 48 | |
| 49 | Use memory=True so blocks can share state. |
| 50 | """ |
| 51 | monkeypatch.chdir(tmp_path) |
| 52 | abs_fpath = Path(__file__).parent.parent / "docs/tutorials/first-tracking.md" |
| 53 | check_md_file(str(abs_fpath), memory=True) |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…