chore: Linear integration fixes (#9538)

This commit is contained in:
Muhsin Keloth
2024-05-29 11:28:13 +05:30
committed by GitHub
parent 59b912f22c
commit a55fffab3a
14 changed files with 188 additions and 25 deletions

View File

@@ -148,6 +148,23 @@ describe Linear do
end
end
context 'when the description is markdown' do
let(:description) { 'Cmd/Ctrl` `K` **is our most powerful feature.** \n\nUse it to search for or take any action in the app' }
before do
stub_request(:post, url)
.to_return(status: 200, body: { success: true,
data: { issueCreate: { id: 'issue1', title: 'Title',
description: description } } }.to_json, headers: headers)
end
it 'creates an issue' do
response = linear_client.create_issue(params)
expect(response).to eq({ 'issueCreate' => { 'id' => 'issue1', 'title' => 'Title',
'description' => description } })
end
end
context 'when the API response is an error' do
before do
stub_request(:post, url)