Sha256: 7ffaf531cc0dc6330163df0b38f115df3d1137fcb2c123491adb2e949090fb9d

Contents?: true

Size: 946 Bytes

Versions: 11

Compression:

Stored size: 946 Bytes

Contents

import { testReducerSnapshotWithFixtures } from 'react-redux-test-utils';

import {
  FOREMAN_TASK_DETAILS_FETCH_TASK_SUCCESS,
  FOREMAN_TASK_DETAILS_STOP_POLLING,
  FOREMAN_TASK_DETAILS_START_POLLING,
} from '../TaskDetailsConstants';
import reducer from '../TaskDetailsReducer';

const fixtures = {
  'should return the initial state': {},
  'should handle FOREMAN_TASK_DETAILS_START_POLLING': {
    action: {
      type: FOREMAN_TASK_DETAILS_START_POLLING,
      payload: { timeoutId: 1 },
    },
  },
  'should handle FOREMAN_TASK_DETAILS_STOP_POLLING': {
    action: {
      type: FOREMAN_TASK_DETAILS_STOP_POLLING,
      payload: { timeoutId: 1 },
    },
  },
  'should handle FOREMAN_TASK_DETAILS_FETCH_TASK_SUCCESS': {
    action: {
      type: FOREMAN_TASK_DETAILS_FETCH_TASK_SUCCESS,
      payload: { data: 'some-payload' },
    },
  },
};

describe('TaskDetails - Reducer', () =>
  testReducerSnapshotWithFixtures(reducer, fixtures));

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
foreman-tasks-0.17.6 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-1.0.0 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.5 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.4 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.3 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.2 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.16.3 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.1 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.16.2 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.16.1 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js
foreman-tasks-0.17.0 webpack/ForemanTasks/Components/TaskDetails/__tests__/TaskDetailsReducer.test.js