Refine prompt
This commit is contained in:
@@ -8,4 +8,18 @@ class Command::ParserTest < ActionDispatch::IntegrationTest
|
||||
result = parse_command "assign @kevin"
|
||||
assert_equal "assign @kevin", result.line
|
||||
end
|
||||
|
||||
test "supports expressions in plain text" do
|
||||
command = parse_command "/assign @kevin"
|
||||
assert command.is_a?(Command::Assign)
|
||||
assert_equal [users(:kevin)], command.assignees
|
||||
end
|
||||
|
||||
test "supports expressions in rich text" do
|
||||
command = parse_command <<~HTML
|
||||
<p>/assign #{ActionText::Attachment.from_attachable(users(:kevin)).to_html}</p>
|
||||
HTML
|
||||
assert command.is_a?(Command::Assign)
|
||||
assert_equal [users(:kevin)], command.assignees
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user