Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion tests/e2e/template_instantiation_test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ find "$TEST_REPO_PATH" -type f \
sed -i "s|$placeholder|$value|g" "$file"
fi
done
' _ "$file"
' _ {} \;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 HIGH RISK

The variables $placeholder and $value are inside a single-quoted string, meaning the parent shell will not expand them. Additionally, using -exec ... {} \; runs the command once per file, making the internal for file in "$@" loop redundant.

Try running the following prompt in your coding agent:

In tests/e2e/template_instantiation_test.sh, modify the find command to pass $placeholder and $value as the first two arguments to the sh -c script, shift 2 inside the script to clear them from the positional parameters, and change the terminator to {} + so the for loop can efficiently process all files.


log_pass "All placeholder tokens replaced"

Expand Down
Loading