Skip to content

Commit

Permalink
Add URL, integration test
Browse files Browse the repository at this point in the history
  • Loading branch information
ChiTimesChi committed Dec 27, 2023
1 parent c232272 commit 43e7190
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
7 changes: 7 additions & 0 deletions packages/sdk-router/src/rfq/api.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,11 @@ describe('getAllQuotes', () => {
unmarshallFastBridgeQuote(quotesAPI[1]),
])
})

it('Integration test', async () => {
global.fetch = require('node-fetch')
const result = await getAllQuotes()
console.log('Quotes: ' + JSON.stringify(result, null, 2))
expect(result.length).toBeGreaterThan(0)
})
})
4 changes: 2 additions & 2 deletions packages/sdk-router/src/rfq/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ import {
unmarshallFastBridgeQuote,
} from './quote'

// TODO: fill
const API_URL = 'API_URL'
// TODO: change to mainnet API URL once it's enabled
const API_URL = 'https://rfq-api-testnet.omnirpc.io'

/**
* Hits Quoter API /quotes endpoint to get all quotes.
Expand Down

0 comments on commit 43e7190

Please sign in to comment.