mirror of
https://github.com/reduxjs/redux-devtools.git
synced 2025-07-26 16:09:50 +03:00
Fix tests
This commit is contained in:
parent
317dbc825c
commit
52c9f50f63
|
@ -17,7 +17,7 @@ describe('Server', function () {
|
|||
|
||||
describe('Express backend', function () {
|
||||
it('loads main page', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||
request('http://localhost:8000')
|
||||
.get('/')
|
||||
|
@ -64,7 +64,7 @@ describe('Server', function () {
|
|||
});
|
||||
|
||||
it('should connect', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
socket.on('connect', function (status) {
|
||||
expect(status.id).toBeTruthy();
|
||||
done();
|
||||
|
@ -89,7 +89,7 @@ describe('Server', function () {
|
|||
});
|
||||
|
||||
it('should send message', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
const data = {
|
||||
type: 'ACTION',
|
||||
payload: {
|
||||
|
@ -146,7 +146,7 @@ describe('Server', function () {
|
|||
'AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.95 Safari/537.36',
|
||||
};
|
||||
it('should add a report', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||
request('http://localhost:8000')
|
||||
.post('/')
|
||||
|
@ -163,7 +163,7 @@ describe('Server', function () {
|
|||
});
|
||||
|
||||
it('should get the report', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||
request('http://localhost:8000')
|
||||
.post('/')
|
||||
|
@ -182,7 +182,7 @@ describe('Server', function () {
|
|||
});
|
||||
|
||||
it('should list reports', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||
request('http://localhost:8000')
|
||||
.post('/')
|
||||
|
@ -207,7 +207,7 @@ describe('Server', function () {
|
|||
|
||||
describe('GraphQL backend', function () {
|
||||
it('should get the report', function () {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
// eslint-disable-next-line @typescript-eslint/no-floating-promises
|
||||
request('http://localhost:8000')
|
||||
.post('/graphql')
|
||||
|
|
|
@ -33,14 +33,14 @@ const StackTraceTabAsAny = StackTraceTab as any;
|
|||
|
||||
describe('StackTraceTab component', () => {
|
||||
it('should render with no props', () => {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
const component = mount(<StackTraceTabAsAny />);
|
||||
genAsyncSnapshot(component, done);
|
||||
});
|
||||
});
|
||||
|
||||
it('should render with props, but without stack', () => {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
const component = mount(
|
||||
<StackTraceTabAsAny actions={actions} action={actions[0].action} />
|
||||
);
|
||||
|
@ -49,7 +49,7 @@ describe('StackTraceTab component', () => {
|
|||
});
|
||||
|
||||
it('should render the link to docs', () => {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
const component = mount(
|
||||
<StackTraceTabAsAny actions={actions} action={actions[1].action} />
|
||||
);
|
||||
|
@ -58,7 +58,7 @@ describe('StackTraceTab component', () => {
|
|||
});
|
||||
|
||||
it('should render with trace stack', () => {
|
||||
return new Promise((done) => {
|
||||
return new Promise<void>((done) => {
|
||||
const component = mount(
|
||||
<StackTraceTabAsAny actions={actions} action={actions[2].action} />
|
||||
);
|
||||
|
|
|
@ -1071,7 +1071,7 @@ describe('instrument', () => {
|
|||
});
|
||||
|
||||
it('should get stack trace inside setTimeout using a function', () =>
|
||||
new Promise((done) => {
|
||||
new Promise<void>((done) => {
|
||||
const stack = new Error().stack;
|
||||
setTimeout(() => {
|
||||
const traceFn = () => stack! + new Error().stack!;
|
||||
|
|
Loading…
Reference in New Issue
Block a user