Use composite commands even for single commands since they can carry custom titles, which is what we want with AI

This commit is contained in:
Jorge Manrubia
2025-07-03 16:26:52 +02:00
parent 7e2f3894f6
commit 702169384c
4 changed files with 7 additions and 14 deletions
+1 -1
View File
@@ -16,7 +16,7 @@ class Command::Ai::ParserTest < ActionDispatch::IntegrationTest
test "resolve filter string params as ids" do
command = parse_command "cards assigned to kevin, tagged with #web, in the collection writebook"
url = command.url
url = command.commands.first.url
query_string = URI.parse(url).query
params = Rack::Utils.parse_nested_query(query_string).with_indifferent_access
+2 -1
View File
@@ -21,6 +21,7 @@ class Command::GoToCardTest < ActionDispatch::IntegrationTest
assert command.valid?
result = command.execute
assert_equal cards_path(terms: [ "123" ]), result.url
assert_equal 1, result.size
assert_equal cards_path(terms: [ "123" ]), result.first.url
end
end