Merge pull request 'Test fixtures get the action the lint now requires' (#28) from fixture-action into main
Test / test (push) Successful in 1m10s

This commit was merged in pull request #28.
This commit is contained in:
bl
2026-10-01 19:46:29 +00:00
+6 -3
View File
@@ -1323,6 +1323,7 @@ alternatives:
public: true public: true
source: {{ kind: kv, bucket: things }} source: {{ kind: kv, bucket: things }}
- name: Object - name: Object
action: /object
record_as: things record_as: things
features: features:
- name: Yours - name: Yours
@@ -1420,6 +1421,7 @@ id: /t
name: Where is it? name: Where is it?
alternatives: alternatives:
- name: A - name: A
action: /t
features: features:
- name: Where - name: Where
requirements: requirements:
@@ -1523,6 +1525,7 @@ id: /b
name: B name: B
alternatives: alternatives:
- name: A - name: A
action: /b
features: features:
- name: "" - name: ""
requirements: requirements:
@@ -1564,7 +1567,7 @@ alternatives:
fn question_with_requirement(req_yaml: &str) -> std::collections::HashMap<String, Question> { fn question_with_requirement(req_yaml: &str) -> std::collections::HashMap<String, Question> {
let question: Question = serde_yaml::from_str(&format!( let question: Question = serde_yaml::from_str(&format!(
"id: /g\nname: G\nalternatives:\n - name: A\n features:\n - name: \"\"\n requirements:\n{req_yaml}\n" "id: /g\nname: G\nalternatives:\n - name: A\n action: /g\n features:\n - name: \"\"\n requirements:\n{req_yaml}\n"
)) ))
.unwrap(); .unwrap();
std::collections::HashMap::from([(question.id.clone(), question)]) std::collections::HashMap::from([(question.id.clone(), question)])
@@ -1835,7 +1838,7 @@ alternatives:
fn recorded_buckets_must_be_attended() { fn recorded_buckets_must_be_attended() {
let write_only = vec![( let write_only = vec![(
"index.yaml".to_string(), "index.yaml".to_string(),
"name: Home\nalternatives:\n - name: send\n record_as: black_hole\n".to_string(), "name: Home\nalternatives:\n - name: send\n action: /\n record_as: black_hole\n".to_string(),
)]; )];
let questions = build_questions(&write_only).unwrap(); let questions = build_questions(&write_only).unwrap();
let err = validate_questions(&questions, &Default::default()).unwrap_err(); let err = validate_questions(&questions, &Default::default()).unwrap_err();
@@ -1846,7 +1849,7 @@ alternatives:
let with_desk = vec![ let with_desk = vec![
( (
"index.yaml".to_string(), "index.yaml".to_string(),
"name: Home\nalternatives:\n - name: send\n record_as: inbox\n".to_string(), "name: Home\nalternatives:\n - name: send\n action: /\n record_as: inbox\n".to_string(),
), ),
( (
"review/index.yaml".to_string(), "review/index.yaml".to_string(),