chore: replace jest with mocha
This commit is contained in:
committed by
Justin Starry
parent
612958ece0
commit
c675c67c26
@ -1,16 +1,19 @@
|
||||
// @flow
|
||||
import {clusterApiUrl} from '../src/util/cluster';
|
||||
import {expect} from 'chai';
|
||||
|
||||
test('invalid', () => {
|
||||
expect(() => {
|
||||
// $FlowExpectedError
|
||||
clusterApiUrl('abc123');
|
||||
}).toThrow();
|
||||
});
|
||||
describe('Cluster Util', () => {
|
||||
it('invalid', () => {
|
||||
expect(() => {
|
||||
// $FlowExpectedError
|
||||
clusterApiUrl('abc123');
|
||||
}).to.throw();
|
||||
});
|
||||
|
||||
test('devnet', () => {
|
||||
expect(clusterApiUrl()).toEqual('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet')).toEqual('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet', true)).toEqual('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet', false)).toEqual('http://devnet.solana.com');
|
||||
it('devnet', () => {
|
||||
expect(clusterApiUrl()).to.eq('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet')).to.eq('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet', true)).to.eq('https://devnet.solana.com');
|
||||
expect(clusterApiUrl('devnet', false)).to.eq('http://devnet.solana.com');
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user