Sha256: fb1b2ea7fa36858b237f4717897f8eef9f2671eee83ce48ad6a4f0be1fed52f7

Contents?: true

Size: 880 Bytes

Versions: 6

Compression:

Stored size: 880 Bytes

Contents

import { testReducerSnapshotWithFixtures } from 'react-redux-test-utils';
import reducer from '../SyncButtonReducer';
import { syncHosts, disconnectHosts, error } from './SyncButtonFixtures';
import {
  INVENTORY_SYNC_REQUEST,
  INVENTORY_SYNC_SUCCESS,
  INVENTORY_SYNC_FAILURE,
} from '../SyncButtonConstants';

const fixtures = {
  'should return the initial state': {},
  'should handle INVENTORY_SYNC_REQUEST': {
    action: {
      type: INVENTORY_SYNC_REQUEST,
      payload: {},
    },
  },
  'should handle INVENTORY_SYNC_SUCCESS': {
    action: {
      type: INVENTORY_SYNC_SUCCESS,
      payload: { syncHosts, disconnectHosts },
    },
  },
  'should handle INVENTORY_SYNC_FAILURE': {
    action: {
      type: INVENTORY_SYNC_FAILURE,
      payload: { error },
    },
  },
};

describe('AccountList reducer', () =>
  testReducerSnapshotWithFixtures(reducer, fixtures));

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
foreman_rh_cloud-0.9.12 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js
foreman_rh_cloud-1.0.12 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js
foreman_rh_cloud-0.9.11 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js
foreman_rh_cloud-1.0.11 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js
foreman_rh_cloud-0.9.10 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js
foreman_rh_cloud-1.0.10 webpack/ForemanInventoryUpload/Components/PageHeader/components/SyncButton/__tests__/SyncButtonReducer.test.js