(expected_key_set, expected_diff=1)
| 155 | v: str |
| 156 | |
| 157 | def run_pathway_program(expected_key_set, expected_diff=1): |
| 158 | table = pw.io.deltalake.read(lake_path, schema=InputSchema, mode="static") |
| 159 | pw.io.csv.write(table, output_path) |
| 160 | |
| 161 | persistence_config = pw.persistence.Config( |
| 162 | pw.persistence.Backend.filesystem(tmp_path / "PStorage"), |
| 163 | snapshot_access=snapshot_access, |
| 164 | ) |
| 165 | run_all(persistence_config=persistence_config) |
| 166 | try: |
| 167 | result = pd.read_csv(output_path) |
| 168 | assert set(result["k"]) == expected_key_set |
| 169 | assert set(result["diff"]) == {expected_diff} |
| 170 | except pd.errors.EmptyDataError: |
| 171 | assert expected_key_set == {} |
| 172 | G.clear() |
| 173 | |
| 174 | run_pathway_program({1, 2, 3}) |
| 175 |
no test coverage detected