Skip to content

Commit

Permalink
Fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
tifrel committed Mar 17, 2023
1 parent 2fd21c9 commit b5c0e2e
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,13 @@ import { META_SERVICE_HOST_TESTNET } from '../../constants';
import { attributesByContract, attributesByContractThrowOnError } from './attributesByContract';
import fetchMock from 'fetch-mock';
import { Attributes } from './attributesByContract.type';
import { mbjs } from '@mintbase-js/sdk';

describe('tokensByAttributes', () => {
beforeAll(() => {
mbjs.config({ network: 'testnet' });
});

beforeEach(() => {
jest.spyOn(console, 'error').mockImplementation(() => {
// console.log('Suppressed console error.');
Expand All @@ -28,5 +33,3 @@ describe('tokensByAttributes', () => {
expect(attributesByContractThrowOnError('contract.id')).rejects.toBeDefined();
});
});


Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@

import { META_SERVICE_HOST_TESTNET } from '../../constants';
import { ParsedDataReturn } from '../../types';
import { FilteredMetadataQueryResult, tokensByAttributes, tokensByAttributesThrowOnError } from './tokensByAttributes';

import fetchMock from 'fetch-mock';
import { mbjs } from '@mintbase-js/sdk';

describe('tokensByAttributes', () => {
beforeAll(() => {
mbjs.config({ network: 'testnet' });
});

beforeEach(() => {
jest.spyOn(console, 'error').mockImplementation(() => {
// console.log('Suppressed console error.');
Expand Down Expand Up @@ -54,5 +58,3 @@ describe('tokensByAttributes', () => {
expect(tokensByAttributesThrowOnError('contract.id', query)).rejects.toBeDefined();
});
});


0 comments on commit b5c0e2e

Please sign in to comment.