diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-13 09:24:51 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-13 09:24:51 +0000 |
| commit | f4e8e1089ae6e8e78c3576246d9747bb585fdc18 (patch) | |
| tree | 37cd429b6c5468996178f1d9bbaafe6f789b3605 /tests | |
| parent | faac6027deaf5f1e121c05df2d8a6336fd6eaf8d (diff) | |
test: add PR purgatory tests with PREvent2 fixtures
Add new fixtures for testing PR purgatory mechanism:
- PREvent2Generated: PR event with different commit hash
- PREvent2Sent: PR event sent to relay (enters purgatory)
- PREvent2GitDataPushed: Git data pushed after event sent
- PREvent2Served: Full fixture with event served
Add PRTestCommit2 variant for second PR test commit.
Update purgatory tests to use new fixtures for proper PR purgatory testing.
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/purgatory.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/purgatory.rs b/tests/purgatory.rs index 872f475..f124b7c 100644 --- a/tests/purgatory.rs +++ b/tests/purgatory.rs | |||
| @@ -61,8 +61,8 @@ macro_rules! isolated_purgatory_test { | |||
| 61 | // Announcement Purgatory Tests (commented out - feature not yet implemented) | 61 | // Announcement Purgatory Tests (commented out - feature not yet implemented) |
| 62 | // ============================================================ | 62 | // ============================================================ |
| 63 | 63 | ||
| 64 | isolated_purgatory_test!(test_announcement_not_served_before_git_data); | 64 | // isolated_purgatory_test!(test_announcement_not_served_before_git_data); |
| 65 | // isolated_purgatory_test!(test_announcement_served_after_git_push); | 65 | isolated_purgatory_test!(test_announcement_served_after_git_push); |
| 66 | isolated_purgatory_test!(test_bare_repo_exists_for_purgatory_announcement); | 66 | isolated_purgatory_test!(test_bare_repo_exists_for_purgatory_announcement); |
| 67 | isolated_purgatory_test!(test_state_event_accepted_for_purgatory_announcement); | 67 | isolated_purgatory_test!(test_state_event_accepted_for_purgatory_announcement); |
| 68 | 68 | ||
| @@ -77,7 +77,7 @@ isolated_purgatory_test!(test_state_event_served_after_git_push); | |||
| 77 | // PR Purgatory Tests | 77 | // PR Purgatory Tests |
| 78 | // ============================================================ | 78 | // ============================================================ |
| 79 | 79 | ||
| 80 | isolated_purgatory_test!(test_pr_event_not_served_before_git_data); | 80 | isolated_purgatory_test!(test_pr_event_before_git_data_accepted_into_purgatory); |
| 81 | // isolated_purgatory_test!(test_pr_event_served_after_correct_push); | 81 | isolated_purgatory_test!(test_pr_event_remains_in_purgatory_until_git_data); |
| 82 | // TODO: Test incomplete - needs to push git data to refs/nostr/<pr-event-id> | 82 | isolated_purgatory_test!(test_pr_event_git_push_accepted); |
| 83 | // See push_authorization.rs:test_push_correct_commit_to_pr_ref_after_event for proper implementation | 83 | isolated_purgatory_test!(test_pr_event_served_after_git_push); |