mirror of
https://github.com/ansible/awx.git
synced 2026-03-20 02:17:37 -02:30
Reorganize file locations/directory structure (#270)
Reorganize file locations
This commit is contained in:
28
src/screens/JobsSetting/JobsSettings.jsx
Normal file
28
src/screens/JobsSetting/JobsSettings.jsx
Normal file
@@ -0,0 +1,28 @@
|
||||
import React, { Component, Fragment } from 'react';
|
||||
import { withI18n } from '@lingui/react';
|
||||
import { t } from '@lingui/macro';
|
||||
import {
|
||||
PageSection,
|
||||
PageSectionVariants,
|
||||
Title,
|
||||
} from '@patternfly/react-core';
|
||||
|
||||
class JobsSettings extends Component {
|
||||
render () {
|
||||
const { i18n } = this.props;
|
||||
const { light, medium } = PageSectionVariants;
|
||||
|
||||
return (
|
||||
<Fragment>
|
||||
<PageSection variant={light} className="pf-m-condensed">
|
||||
<Title size="2xl">
|
||||
{i18n._(t`Jobs Settings`)}
|
||||
</Title>
|
||||
</PageSection>
|
||||
<PageSection variant={medium} />
|
||||
</Fragment>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
export default withI18n()(JobsSettings);
|
||||
29
src/screens/JobsSetting/JobsSettings.test.jsx
Normal file
29
src/screens/JobsSetting/JobsSettings.test.jsx
Normal file
@@ -0,0 +1,29 @@
|
||||
import React from 'react';
|
||||
import { mountWithContexts } from '../../../testUtils/enzymeHelpers';
|
||||
import JobsSettings from './JobsSettings';
|
||||
|
||||
describe('<JobsSettings />', () => {
|
||||
let pageWrapper;
|
||||
let pageSections;
|
||||
let title;
|
||||
|
||||
beforeEach(() => {
|
||||
pageWrapper = mountWithContexts(<JobsSettings />);
|
||||
pageSections = pageWrapper.find('PageSection');
|
||||
title = pageWrapper.find('Title');
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
pageWrapper.unmount();
|
||||
});
|
||||
|
||||
test('initially renders without crashing', () => {
|
||||
expect(pageWrapper.length).toBe(1);
|
||||
expect(pageSections.length).toBe(2);
|
||||
expect(title.length).toBe(1);
|
||||
expect(title.props().size).toBe('2xl');
|
||||
pageSections.forEach(section => {
|
||||
expect(section.props().variant).toBeDefined();
|
||||
});
|
||||
});
|
||||
});
|
||||
1
src/screens/JobsSetting/index.js
Normal file
1
src/screens/JobsSetting/index.js
Normal file
@@ -0,0 +1 @@
|
||||
export { default } from './JobsSettings';
|
||||
Reference in New Issue
Block a user