huskies: merge 864
This commit is contained in:
@@ -57,7 +57,12 @@ mod tests {
|
||||
.unwrap();
|
||||
// Place the story in 2_current/ via CRDT (the only source of truth).
|
||||
crate::db::ensure_content_store();
|
||||
crate::db::write_item_with_content("story-3", "2_current", "---\nname: Story 3\n---\n");
|
||||
crate::db::write_item_with_content(
|
||||
"story-3",
|
||||
"2_current",
|
||||
"---\nname: Story 3\n---\n",
|
||||
crate::db::ItemMeta::named("Story 3"),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
// No agents are running — coder-1 is free.
|
||||
@@ -139,6 +144,11 @@ mod tests {
|
||||
"9930_story_qa1",
|
||||
"3_qa",
|
||||
"---\nname: QA Story\nagent: coder-1\n---\n",
|
||||
crate::db::ItemMeta {
|
||||
name: Some("QA Story".into()),
|
||||
agent: Some("coder-1".into()),
|
||||
..Default::default()
|
||||
},
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -188,6 +198,11 @@ mod tests {
|
||||
"story-pref",
|
||||
"2_current",
|
||||
"---\nname: Coder Story\nagent: coder-1\n---\n",
|
||||
crate::db::ItemMeta {
|
||||
name: Some("Coder Story".into()),
|
||||
agent: Some("coder-1".into()),
|
||||
..Default::default()
|
||||
},
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -235,6 +250,11 @@ mod tests {
|
||||
"9931_story_noqa",
|
||||
"3_qa",
|
||||
"---\nname: QA Story No Agent\nagent: coder-1\n---\n",
|
||||
crate::db::ItemMeta {
|
||||
name: Some("QA Story No Agent".into()),
|
||||
agent: Some("coder-1".into()),
|
||||
..Default::default()
|
||||
},
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -274,6 +294,7 @@ mod tests {
|
||||
"9932_story_waiting",
|
||||
"2_current",
|
||||
"---\nname: Waiting\ndepends_on: [9999]\n---\n",
|
||||
crate::db::ItemMeta::from_yaml("---\nname: Waiting\ndepends_on: [9999]\n---\n"),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -307,12 +328,18 @@ mod tests {
|
||||
// Seed stories via CRDT (the only source of truth).
|
||||
crate::db::ensure_content_store();
|
||||
// Dep 999 is now done.
|
||||
crate::db::write_item_with_content("999_story_dep", "5_done", "---\nname: Dep\n---\n");
|
||||
crate::db::write_item_with_content(
|
||||
"999_story_dep",
|
||||
"5_done",
|
||||
"---\nname: Dep\n---\n",
|
||||
crate::db::ItemMeta::from_yaml("---\nname: Dep\n---\n"),
|
||||
);
|
||||
// Story 10 depends on 999 which is done.
|
||||
crate::db::write_item_with_content(
|
||||
"10_story_unblocked",
|
||||
"2_current",
|
||||
"---\nname: Unblocked\ndepends_on: [999]\n---\n",
|
||||
crate::db::ItemMeta::from_yaml("---\nname: Unblocked\ndepends_on: [999]\n---\n"),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -496,6 +523,9 @@ mod tests {
|
||||
"9860_story_conflict",
|
||||
"4_merge",
|
||||
"---\nname: Conflict\nmerge_failure: \"CONFLICT (content): server/src/lib.rs\"\n---\n",
|
||||
crate::db::ItemMeta::from_yaml(
|
||||
"---\nname: Conflict\nmerge_failure: \"CONFLICT (content): server/src/lib.rs\"\n---\n",
|
||||
),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -530,6 +560,9 @@ mod tests {
|
||||
"9861_story_nothing",
|
||||
"4_merge",
|
||||
"---\nname: Nothing\nmerge_failure: \"nothing to commit, working tree clean\"\n---\n",
|
||||
crate::db::ItemMeta::from_yaml(
|
||||
"---\nname: Nothing\nmerge_failure: \"nothing to commit, working tree clean\"\n---\n",
|
||||
),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -565,6 +598,9 @@ mod tests {
|
||||
"9863_story_blocked_conflict",
|
||||
"4_merge",
|
||||
"---\nname: Blocked conflict\nmerge_failure: \"CONFLICT (content): foo.rs\"\nblocked: true\n---\n",
|
||||
crate::db::ItemMeta::from_yaml(
|
||||
"---\nname: Blocked conflict\nmerge_failure: \"CONFLICT (content): foo.rs\"\nblocked: true\n---\n",
|
||||
),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
@@ -599,6 +635,9 @@ mod tests {
|
||||
"9862_story_attempted",
|
||||
"4_merge",
|
||||
"---\nname: Already tried\nmerge_failure: \"CONFLICT (content): foo.rs\"\nmergemaster_attempted: true\n---\n",
|
||||
crate::db::ItemMeta::from_yaml(
|
||||
"---\nname: Already tried\nmerge_failure: \"CONFLICT (content): foo.rs\"\nmergemaster_attempted: true\n---\n",
|
||||
),
|
||||
);
|
||||
|
||||
let pool = AgentPool::new_test(3001);
|
||||
|
||||
Reference in New Issue
Block a user