Тесты для стейтов AuthFlow

This commit is contained in:
SleepWalker
2016-03-21 08:16:37 +02:00
parent 1e9b48bd9b
commit 21bbba399f
17 changed files with 985 additions and 17 deletions

View File

@@ -0,0 +1,29 @@
import FinishState from 'services/authFlow/FinishState';
import { bootstrap, expectNavigate } from './helpers';
describe('FinishState', () => {
let state;
let context;
let mock;
beforeEach(() => {
state = new FinishState();
const data = bootstrap();
context = data.context;
mock = data.mock;
});
afterEach(() => {
mock.verify();
});
describe('#enter', () => {
it('should navigate to /oauth/finish', () => {
expectNavigate(mock, '/oauth/finish');
state.enter(context);
});
});
});