Sha256: afa0df0c1d0a0806628429f2028f2a26133d948c030e5b21ba9b8baa1f11f767

Contents?: true

Size: 1.36 KB

Versions: 10

Compression:

Stored size: 1.36 KB

Contents

import { testSelectorsSnapshotWithFixtures } from 'react-redux-test-utils';
import {
  selectAccountsList,
  selectAccounts,
  selectPollingProcessID,
  selectAutoUploadEnabled,
  selectHostObfuscationEnabled,
  selectCloudToken,
  selectExcludePackages,
} from '../AccountListSelectors';
import {
  pollingProcessID,
  accounts,
  autoUploadEnabled,
  hostObfuscationEnabled,
  cloudToken,
  excludePackages,
} from '../AccountList.fixtures';
import { rhCloudStateWrapper } from '../../../../ForemanRhCloudTestHelpers';

const state = rhCloudStateWrapper({
  accountsList: {
    accounts,
    pollingProcessID,
    autoUploadEnabled,
    hostObfuscationEnabled,
    cloudToken,
    excludePackages,
  },
});

const fixtures = {
  'should return AccountsList': () => selectAccountsList(state),
  'should return AccountList accounts': () => selectAccounts(state),
  'should return AccountList pollingProcessID': () =>
    selectPollingProcessID(state),
  'should return AccountList autoUploadEnabled': () =>
    selectAutoUploadEnabled(state),
  'should return AccountList hostObfuscationEnabled': () =>
    selectHostObfuscationEnabled(state),
  'should return AccountList cloudToken': () => selectCloudToken(state),
  'should return AccountList excludePackages': () =>
    selectExcludePackages(state),
};

describe('AccountList selectors', () =>
  testSelectorsSnapshotWithFixtures(fixtures));

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
foreman_rh_cloud-1.0.18 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.17 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.16 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.15 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.14 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-0.9.14 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-0.9.13.1 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.13.1 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-0.9.13 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js
foreman_rh_cloud-1.0.13 webpack/ForemanInventoryUpload/Components/AccountList/__tests__/AccountListSelectors.test.js