Skip to content

Commit

Permalink
modified roadblock trigger
Browse files Browse the repository at this point in the history
  • Loading branch information
mayurvir committed Apr 13, 2024
1 parent 48f85a9 commit 5389718
Showing 1 changed file with 0 additions and 18 deletions.
18 changes: 0 additions & 18 deletions tests/unit/controllers/controlCenter.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,29 +88,11 @@ describe('API tests for /update-catalog endpoint for an end to end Notify Messag

describe('API tests for triggering a roadblock', ()=>{
it('Should trigger a roadblock on a selected route', async ()=>{
const ask1 = "Can you get routes from Denver to Yellowstone national park?";
await request(app).post('/webhook').send({
"From": process.env.TEST_RECEPIENT_NUMBER,
"Body": ask1
})

const ask2 = "Lets select the first route.";
await request(app).post('/webhook').send({
"From": process.env.TEST_RECEPIENT_NUMBER,
"Body": ask2
})

const response = await request(app).post('/trigger-exception').send({
"point":[39.7408351, -104.9874105],
"message": "There is a roadblock on your selected route due to an accident!"
})

const ask3 = "I'm near Glendo";
await request(app).post('/webhook').send({
"From": process.env.TEST_RECEPIENT_NUMBER,
"Body": ask3
})

expect(response.status).equal(200)
})
})

0 comments on commit 5389718

Please sign in to comment.