Skip to content

armgit / macro

Public Imported from GitHub
0

Macro is a unified workspace for teams: email, chat, docs, tasks, agents, calls, and CRM — @-linked together with shared AI memory.

generify test (#5329)

Will Hutchinson2b85e46447dd
diff --git a/crates/github/src/domain/models/test.rs b/crates/github/src/domain/models/test.rs
index d9a6a74f98..22b091c52c 100644
--- a/crates/github/src/domain/models/test.rs
+++ b/crates/github/src/domain/models/test.rs
@@ -987,9 +987,9 @@ fn strip_markdown_code_plain_text_unchanged() {
assert_eq!(strip_markdown_code(text), text);
}
-// Regression: dungeonbooks/guild#205 — a review quoting a Tailwind class list
-// (`py-6`) must not produce a task reference for a team with slug PY, while
-// the reference in the branch name still resolves.
+// Regression: a review quoting a Tailwind class list (`py-6`) must not
+// produce a task reference for a team with slug PY, while the reference in
+// the branch name still resolves.
#[test]
fn extract_text_strips_code_from_review_body() {
let payload = serde_json::json!({
@@ -1010,9 +1010,9 @@ fn extract_text_strips_code_from_pr_body_but_keeps_branch() {
let payload = serde_json::json!({
"action": "opened",
"pull_request": {
- "title": "fix(dashboard): make the mobile sidebar dismissable",
- "body": "Swap `pt-4` for `py-6` on the sheet container.",
- "head": { "ref": "ptaranat/db-27-mobile-hard-to-tap-out-of-sidebar" }
+ "title": "fix: adjust panel padding",
+ "body": "Swap `pt-4` for `py-6` on the panel container.",
+ "head": { "ref": "someuser/db-27-adjust-panel-padding" }
}
});
let event = ValidatedGithubWebhookEvent::new("pull_request".to_string(), payload);
diff --git a/crates/github/src/domain/service/sync/test.rs b/crates/github/src/domain/service/sync/test.rs
index 4b86767306..73884747aa 100644
--- a/crates/github/src/domain/service/sync/test.rs
+++ b/crates/github/src/domain/service/sync/test.rs
@@ -1544,8 +1544,8 @@ async fn team_task_id_requires_installation_team_match() {
assert!(service.client.pr_comments().is_empty());
}
-// Regression for dungeonbooks/guild#205: a PR body/review quoting the
-// Tailwind class `py-6` in markdown code must not link team PY's task 6.
+// Regression: a PR body/review quoting the Tailwind class `py-6` in
+// markdown code must not link team PY's task 6.
#[tokio::test]
async fn team_task_reference_inside_markdown_code_links_nothing() {
let task_id = MacroTaskId::from_uuid(&uuid::Uuid::parse_str(KNOWN_TASK_UUID).unwrap());
@@ -1559,13 +1559,13 @@ async fn team_task_reference_inside_markdown_code_links_nothing() {
"action": "opened",
"pull_request": {
"number": 205,
- "title": "fix(dashboard): make the mobile sidebar dismissable",
- "body": "Swap `pt-4` for `py-6` on the sheet container.\n```tsx\n<aside class=\"py-6 px-4\">\n```",
- "head": { "ref": "ptaranat/mobile-sidebar-dismiss" }
+ "title": "fix: adjust panel padding",
+ "body": "Swap `pt-4` for `py-6` on the panel container.\n```tsx\n<aside class=\"py-6 px-4\">\n```",
+ "head": { "ref": "someuser/adjust-panel-padding" }
},
"repository": {
- "name": "guild",
- "owner": { "login": "dungeonbooks" }
+ "name": "my-repo",
+ "owner": { "login": "my-org" }
},
"installation": { "id": 12345 }
}),
@@ -1577,7 +1577,7 @@ async fn team_task_reference_inside_markdown_code_links_nothing() {
assert!(service.client.pr_comments().is_empty());
let tracked = service
.repo
- .get_task_ids(GithubKey::new("dungeonbooks", "guild", 205))
+ .get_task_ids(GithubKey::new("my-org", "my-repo", 205))
.await
.unwrap();
assert!(tracked.is_empty());