mirror of
https://github.com/oceanprotocol-archive/squid-js.git
synced 2024-02-02 15:31:51 +01:00
522a4ff2e6
# Conflicts: # test/aquarius/Aquarius.test.ts
38 lines
952 B
TypeScript
38 lines
952 B
TypeScript
import * as assert from "assert"
|
|
import Aquarius from "../../src/aquarius/Aquarius"
|
|
import AquariusConnectorProvider from "../../src/aquarius/AquariusConnectorProvider"
|
|
import config from "../config"
|
|
import AquariusConnectorMock from "../mocks/AquariusConnector.mock"
|
|
|
|
describe("Aquarius", () => {
|
|
|
|
before(() => {
|
|
AquariusConnectorProvider.setConnector(new AquariusConnectorMock())
|
|
})
|
|
|
|
describe("#queryMetadata()", () => {
|
|
|
|
it("should query metadata", async () => {
|
|
|
|
const aquarius: Aquarius = new Aquarius(config)
|
|
|
|
const query = {
|
|
offset: 100,
|
|
page: 0,
|
|
query: {
|
|
value: 1,
|
|
},
|
|
sort: {
|
|
value: 1,
|
|
},
|
|
text: "Office",
|
|
}
|
|
|
|
const result: any[] = await aquarius.queryMetadata(query)
|
|
assert(result)
|
|
})
|
|
|
|
})
|
|
|
|
})
|