foreman_webhooks 5.0.3 → 6.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. checksums.yaml +4 -4
  2. data/Rakefile +0 -15
  3. data/app/models/webhook.rb +1 -1
  4. data/lib/foreman_webhooks/engine.rb +1 -1
  5. data/lib/foreman_webhooks/version.rb +1 -1
  6. data/webpack/ForemanWebhooks/Routes/ForemanWebhooksRoutes.js +1 -1
  7. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/WebhookFormTabs.js +4 -6
  8. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/actionCellFormatter.test.js +109 -0
  9. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/enabledCellFormatter.test.js +38 -0
  10. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/nameToEditFormatter.test.js +82 -0
  11. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/actionCellFormatter.js +23 -0
  12. data/webpack/ForemanWebhooks/Routes/Webhooks/{WebhooksIndexPage/Components/WebhooksTable/Components/EnabledCell.js → Components/WebhookTable/Components/Formatters/enabledCellFormatter.js} +6 -1
  13. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/nameToEditFormatter.js +33 -0
  14. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookCreateModal.js +1 -0
  15. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookDeleteModal.js +5 -1
  16. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookEditModal.js +1 -0
  17. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookTestModal.js +1 -2
  18. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/WebhooksIndexPage.js +120 -16
  19. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/WebhooksIndexPage.test.js +130 -22
  20. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/integration.test.js +10 -3
  21. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/mocks/MockForemanTableIndexPage.js +37 -0
  22. data/webpack/ForemanWebhooks/Routes/Webhooks/constants.js +3 -3
  23. data/webpack/test_setup.js +3 -0
  24. metadata +18 -96
  25. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/FieldConstructor.js +0 -312
  26. data/webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/__tests__/FieldConstructor.test.js +0 -216
  27. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/EmptyWebhooksTable/index.js +0 -29
  28. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/__tests__/__snapshots__/enabledCellFormatter.test.js.snap +0 -7
  29. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/__tests__/enabledCellFormatter.test.js +0 -7
  30. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/actionCellFormatter.js +0 -20
  31. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/enabledCellFormatter.js +0 -6
  32. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/index.js +0 -3
  33. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/nameToEditFormatter.js +0 -19
  34. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/NameToEditCell.js +0 -42
  35. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/__tests__/EnabledCell.test.js +0 -14
  36. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/__tests__/__snapshots__/EnabledCell.test.js.snap +0 -5
  37. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/WebhooksTable.js +0 -121
  38. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/WebhooksTableSchema.js +0 -48
  39. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/__tests__/WebhooksTable.test.js +0 -64
  40. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/__tests__/__snapshots__/WebhooksTable.test.js.snap +0 -250
  41. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/index.js +0 -76
  42. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/__snapshots__/WebhooksIndexPage.test.js.snap +0 -17
  43. data/webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/index.js +0 -3
  44. data/webpack/__mocks__/foremanReact/Root/Context/ForemanContext.js +0 -1
  45. data/webpack/__mocks__/foremanReact/common/HOC.js +0 -30
  46. data/webpack/__mocks__/foremanReact/common/I18n.js +0 -7
  47. data/webpack/__mocks__/foremanReact/common/helpers.js +0 -7
  48. data/webpack/__mocks__/foremanReact/common/urlHelpers.js +0 -8
  49. data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js +0 -2
  50. data/webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalHooks.js +0 -10
  51. data/webpack/__mocks__/foremanReact/components/ForemanModal/index.js +0 -23
  52. data/webpack/__mocks__/foremanReact/components/Layout/LayoutActions.js +0 -2
  53. data/webpack/__mocks__/foremanReact/components/Loading/Loading.js +0 -2
  54. data/webpack/__mocks__/foremanReact/components/Loading/index.js +0 -3
  55. data/webpack/__mocks__/foremanReact/components/PF4/TableIndexPage/TableIndexPage.js +0 -10
  56. data/webpack/__mocks__/foremanReact/components/Pagination/index.js +0 -4
  57. data/webpack/__mocks__/foremanReact/components/common/ActionButtons/ActionButtons.js +0 -3
  58. data/webpack/__mocks__/foremanReact/components/common/EmptyState.js +0 -5
  59. data/webpack/__mocks__/foremanReact/components/common/forms/ForemanForm.js +0 -9
  60. data/webpack/__mocks__/foremanReact/components/common/forms/FormField.js +0 -3
  61. data/webpack/__mocks__/foremanReact/components/common/table.js +0 -26
  62. data/webpack/__mocks__/foremanReact/constants.js +0 -24
  63. data/webpack/__mocks__/foremanReact/history.js +0 -3
  64. data/webpack/__mocks__/foremanReact/redux/API/APISelectors.js +0 -6
  65. data/webpack/__mocks__/foremanReact/redux/API/index.js +0 -10
  66. data/webpack/__mocks__/foremanReact/redux/actions/common/forms.js +0 -1
  67. data/webpack/__mocks__/foremanReact/redux/actions/toasts.js +0 -8
  68. data/webpack/__mocks__/foremanReact/routes/common/PageLayout/PageLayout.js +0 -10
  69. /data/webpack/ForemanWebhooks/Routes/Webhooks/{WebhooksIndexPage/Components/WebhooksTable → Components/WebhookTable}/Components/ActionButtons/ActionButton.js +0 -0
@@ -1,32 +1,140 @@
1
1
  import React from 'react';
2
- import { testComponentSnapshotsWithFixtures } from '@theforeman/test';
2
+ import { render, screen, fireEvent } from '@testing-library/react';
3
+ import '@testing-library/jest-dom';
3
4
  import { Provider } from 'react-redux';
4
5
  import { createStore } from 'redux';
5
6
 
7
+ import mockForemanTableIndexPage from './mocks/MockForemanTableIndexPage';
8
+
9
+ import * as selectors from '../../WebhooksPageSelectors';
6
10
  import WebhooksIndexPage from '../WebhooksIndexPage';
11
+ import {
12
+ spySelector,
13
+ webhooks as webhooksFixture,
14
+ } from './WebhooksIndexPage.fixtures';
15
+
16
+ jest.mock(
17
+ '../../Components/WebhookTable/Components/Formatters/nameToEditFormatter',
18
+ () => ({
19
+ __esModule: true,
20
+ default: () => () => null,
21
+ })
22
+ );
23
+ jest.mock(
24
+ '../../Components/WebhookTable/Components/Formatters/enabledCellFormatter',
25
+ () => ({
26
+ __esModule: true,
27
+ default: () => () => null,
28
+ })
29
+ );
30
+ jest.mock(
31
+ '../../Components/WebhookTable/Components/Formatters/actionCellFormatter',
32
+ () => ({
33
+ __esModule: true,
34
+ default: () => () => null,
35
+ })
36
+ );
37
+
38
+ jest.mock('foremanReact/components/PF4/TableIndexPage/TableIndexPage', () => ({
39
+ __esModule: true,
40
+ default: mockForemanTableIndexPage,
41
+ }));
42
+
43
+ jest.mock('../Components/WebhookCreateModal', () => ({
44
+ __esModule: true,
45
+ default: ({ isOpen, onCancel }) =>
46
+ isOpen ? (
47
+ <div data-testid="webhook-create-modal">
48
+ <button type="button" onClick={onCancel}>
49
+ Close create modal
50
+ </button>
51
+ </div>
52
+ ) : null,
53
+ }));
54
+
55
+ jest.mock('../Components/WebhookDeleteModal', () => ({
56
+ __esModule: true,
57
+ default: ({ modalState }) =>
58
+ modalState.isOpen ? (
59
+ <div data-testid="webhook-delete-modal">Delete modal</div>
60
+ ) : null,
61
+ }));
62
+
63
+ jest.mock('../Components/WebhookEditModal', () => ({
64
+ __esModule: true,
65
+ default: ({ modalState }) =>
66
+ modalState.isOpen ? (
67
+ <div data-testid="webhook-edit-modal">Edit modal</div>
68
+ ) : null,
69
+ }));
70
+
71
+ jest.mock('../Components/WebhookTestModal', () => ({
72
+ __esModule: true,
73
+ default: ({ modalState }) =>
74
+ modalState.isOpen ? (
75
+ <div data-testid="webhook-test-modal">Test modal</div>
76
+ ) : null,
77
+ }));
7
78
 
8
- const fixtures = {
9
- 'render with minimal props': {
10
- fetchAndPush: jest.fn(),
11
- reloadWithSearch: jest.fn(),
12
- handleCreateSubmit: jest.fn(),
13
- isLoading: false,
14
- hasError: false,
15
- hasData: false,
16
- itemCount: 0,
17
- canCreate: true,
18
- sort: {},
19
- webhooks: [],
20
- },
21
- };
79
+ const store = createStore((state = {}) => state);
80
+
81
+ const renderPage = () =>
82
+ render(
83
+ <Provider store={store}>
84
+ <WebhooksIndexPage />
85
+ </Provider>
86
+ );
22
87
 
23
88
  describe('WebhooksIndexPage', () => {
24
- describe('redering', () => {
25
- const webhooksPage = () => (
26
- <Provider store={createStore((state = [], action) => state)}>
27
- <WebhooksIndexPage />
28
- </Provider>
29
- );
30
- testComponentSnapshotsWithFixtures(webhooksPage, fixtures);
89
+ beforeAll(() => {
90
+ spySelector(selectors);
91
+ });
92
+
93
+ beforeEach(() => {
94
+ jest.clearAllMocks();
95
+ selectors.selectWebhooks.mockImplementation(() => []);
96
+ });
97
+
98
+ it('renders the webhooks header', () => {
99
+ renderPage();
100
+
101
+ expect(
102
+ screen.getByRole('heading', { name: 'Webhooks' })
103
+ ).toBeInTheDocument();
104
+ expect(screen.getByTestId('webhooks-table-index')).toBeInTheDocument();
105
+ });
106
+
107
+ it('renders webhook rows from the store', () => {
108
+ selectors.selectWebhooks.mockImplementation(() => webhooksFixture);
109
+
110
+ renderPage();
111
+
112
+ expect(screen.getByText('my-webhook')).toBeInTheDocument();
113
+ expect(screen.getByText('your-webhook')).toBeInTheDocument();
114
+ });
115
+
116
+ it('opens the create modal when Create new is clicked', () => {
117
+ renderPage();
118
+
119
+ expect(
120
+ screen.queryByTestId('webhook-create-modal')
121
+ ).not.toBeInTheDocument();
122
+
123
+ fireEvent.click(screen.getByRole('button', { name: 'Create new' }));
124
+
125
+ expect(screen.getByTestId('webhook-create-modal')).toBeInTheDocument();
126
+ });
127
+
128
+ it('closes the create modal when cancel is triggered', () => {
129
+ renderPage();
130
+
131
+ fireEvent.click(screen.getByRole('button', { name: 'Create new' }));
132
+ expect(screen.getByTestId('webhook-create-modal')).toBeInTheDocument();
133
+
134
+ fireEvent.click(screen.getByRole('button', { name: 'Close create modal' }));
135
+
136
+ expect(
137
+ screen.queryByTestId('webhook-create-modal')
138
+ ).not.toBeInTheDocument();
31
139
  });
32
140
  });
@@ -2,8 +2,12 @@ import React from 'react';
2
2
  import { IntegrationTestHelper } from '@theforeman/test';
3
3
  import { Router } from 'react-router-dom';
4
4
  import { createMemoryHistory } from 'history';
5
+ import {
6
+ reducers as foremanApiReducers,
7
+ APIMiddleware,
8
+ } from 'foremanReact/redux/API';
5
9
 
6
- import ConnectedWebhooksIndexPage from '../index';
10
+ import ConnectedWebhooksIndexPage from '../WebhooksIndexPage';
7
11
 
8
12
  import * as selectors from '../../WebhooksPageSelectors';
9
13
  import * as editSelectors from '../Components/WebhookEditModalSelectors';
@@ -17,7 +21,10 @@ describe('WebhooksIndexPage - Integration Test', () => {
17
21
  const history = createMemoryHistory();
18
22
  history.push({ pathname: '/webhooks', search: '' });
19
23
 
20
- const integrationTestHelper = new IntegrationTestHelper();
24
+ const integrationTestHelper = new IntegrationTestHelper(
25
+ foremanApiReducers,
26
+ [APIMiddleware]
27
+ );
21
28
 
22
29
  const component = integrationTestHelper.mount(
23
30
  <Router history={history}>
@@ -25,7 +32,7 @@ describe('WebhooksIndexPage - Integration Test', () => {
25
32
  </Router>
26
33
  );
27
34
 
28
- expect(component.exists('WebhooksTable')).toEqual(true);
35
+ expect(component.find('table[role="grid"]').exists()).toEqual(true);
29
36
  expect(component.exists('WebhookCreateModal')).toEqual(true);
30
37
  });
31
38
  });
@@ -0,0 +1,37 @@
1
+ import React from 'react';
2
+ import PropTypes from 'prop-types';
3
+ import { useSelector } from 'react-redux';
4
+
5
+ import { selectWebhooks } from '../../../WebhooksPageSelectors';
6
+
7
+ function MockForemanTableIndexPage({ header, customCreateAction }) {
8
+ const rows = useSelector(selectWebhooks);
9
+ const onCreate = customCreateAction ? customCreateAction() : undefined;
10
+ return (
11
+ <div data-testid="webhooks-table-index">
12
+ <h1>{header}</h1>
13
+ <ul aria-label="webhook-rows">
14
+ {rows.map(row => (
15
+ <li key={row.id}>{row.name}</li>
16
+ ))}
17
+ </ul>
18
+ {onCreate ? (
19
+ <button type="button" onClick={onCreate}>
20
+ Create new
21
+ </button>
22
+ ) : null}
23
+ </div>
24
+ );
25
+ }
26
+
27
+ MockForemanTableIndexPage.propTypes = {
28
+ header: PropTypes.string,
29
+ customCreateAction: PropTypes.func,
30
+ };
31
+
32
+ MockForemanTableIndexPage.defaultProps = {
33
+ header: '',
34
+ customCreateAction: null,
35
+ };
36
+
37
+ export default MockForemanTableIndexPage;
@@ -4,13 +4,13 @@ export const WEBHOOKS_PAGE_HIDE_LOADING = 'WEBHOOKS_PAGE_HIDE_LOADING';
4
4
  export const WEBHOOKS_PAGE_SHOW_LOADING = 'WEBHOOKS_PAGE_SHOW_LOADING';
5
5
  export const WEBHOOKS_PAGE_CLEAR_ERROR = 'WEBHOOKS_PAGE_CLEAR_ERROR';
6
6
 
7
- export const WEBHOOKS_API_PATH = '/api/v2/webhooks?include_permissions=true';
7
+ export const WEBHOOKS_API_PATH = '/api/webhooks?include_permissions=true';
8
8
  export const WEBHOOKS_PATH = '/webhooks';
9
- export const WEBHOOKS_API_REQUEST_KEY = 'WEBHOOKS';
9
+ export const WEBHOOKS_API_REQUEST_KEY = 'webhooks';
10
10
 
11
11
  export const WEBHOOK_TEMPLATES_API_PATH =
12
12
  '/api/v2/webhook_templates?include_permissions=true';
13
- export const WEBHOOKS_API_PLAIN_PATH = '/api/v2/webhooks';
13
+ export const WEBHOOKS_API_PLAIN_PATH = '/api/webhooks';
14
14
  export const WEBHOOK_TEMPLATES_API_REQUEST_KEY = 'WEBHOOK_TEMPLATES';
15
15
  export const WEBHOOK_API_REQUEST_KEY = 'WEBHOOK';
16
16
  export const WEBHOOK_API_UPDATE_KEY = 'WEBHOOK_UPDATE';
@@ -1,3 +1,6 @@
1
+ // eslint-disable-next-line import/no-unresolved
2
+ import 'foremanJSTestSetup';
3
+
1
4
  jest.mock('foremanReact/history', () => ({
2
5
  history: {
3
6
  action: 'PUSH',
metadata CHANGED
@@ -1,56 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_webhooks
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.3
4
+ version: 6.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Timo Goebel
8
8
  bindir: bin
9
9
  cert_chain: []
10
10
  date: 1980-01-02 00:00:00.000000000 Z
11
- dependencies:
12
- - !ruby/object:Gem::Dependency
13
- name: rake
14
- requirement: !ruby/object:Gem::Requirement
15
- requirements:
16
- - - ">="
17
- - !ruby/object:Gem::Version
18
- version: '0'
19
- type: :development
20
- prerelease: false
21
- version_requirements: !ruby/object:Gem::Requirement
22
- requirements:
23
- - - ">="
24
- - !ruby/object:Gem::Version
25
- version: '0'
26
- - !ruby/object:Gem::Dependency
27
- name: rdoc
28
- requirement: !ruby/object:Gem::Requirement
29
- requirements:
30
- - - ">="
31
- - !ruby/object:Gem::Version
32
- version: '0'
33
- type: :development
34
- prerelease: false
35
- version_requirements: !ruby/object:Gem::Requirement
36
- requirements:
37
- - - ">="
38
- - !ruby/object:Gem::Version
39
- version: '0'
40
- - !ruby/object:Gem::Dependency
41
- name: theforeman-rubocop
42
- requirement: !ruby/object:Gem::Requirement
43
- requirements:
44
- - - "~>"
45
- - !ruby/object:Gem::Version
46
- version: 0.1.0
47
- type: :development
48
- prerelease: false
49
- version_requirements: !ruby/object:Gem::Requirement
50
- requirements:
51
- - - "~>"
52
- - !ruby/object:Gem::Version
53
- version: 0.1.0
11
+ dependencies: []
54
12
  description: Plugin for Foreman that allows to configure Webhooks.
55
13
  email:
56
14
  - mail@timogoebel.name
@@ -180,44 +138,31 @@ files:
180
138
  - test/test_plugin_helper.rb
181
139
  - test/unit/foreman_webhooks/webhook_service_test.rb
182
140
  - webpack/ForemanWebhooks/Routes/ForemanWebhooksRoutes.js
183
- - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/FieldConstructor.js
184
141
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/WebhookFormTabs.css
185
142
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/WebhookFormTabs.js
186
- - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/__tests__/FieldConstructor.test.js
187
143
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/WebhookForm.js
188
144
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/WebhookFormSelectors.js
189
145
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/__tests__/WebhookForm.test.js
190
146
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/constants.js
191
147
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/index.js
148
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/ActionButtons/ActionButton.js
149
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/actionCellFormatter.test.js
150
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/enabledCellFormatter.test.js
151
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/nameToEditFormatter.test.js
152
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/actionCellFormatter.js
153
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/enabledCellFormatter.js
154
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/nameToEditFormatter.js
192
155
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookCreateModal.js
193
156
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookDeleteModal.js
194
157
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookEditModal.js
195
158
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookEditModalSelectors.js
196
159
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookModal.scss
197
160
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhookTestModal.js
198
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/ActionButtons/ActionButton.js
199
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/EmptyWebhooksTable/index.js
200
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/EnabledCell.js
201
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/__tests__/__snapshots__/enabledCellFormatter.test.js.snap
202
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/__tests__/enabledCellFormatter.test.js
203
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/actionCellFormatter.js
204
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/enabledCellFormatter.js
205
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/index.js
206
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/nameToEditFormatter.js
207
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/NameToEditCell.js
208
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/__tests__/EnabledCell.test.js
209
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/__tests__/__snapshots__/EnabledCell.test.js.snap
210
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/WebhooksTable.js
211
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/WebhooksTableSchema.js
212
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/__tests__/WebhooksTable.test.js
213
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/__tests__/__snapshots__/WebhooksTable.test.js.snap
214
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/index.js
215
161
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/WebhooksIndexPage.js
216
162
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/WebhooksIndexPage.fixtures.js
217
163
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/WebhooksIndexPage.test.js
218
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/__snapshots__/WebhooksIndexPage.test.js.snap
219
164
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/integration.test.js
220
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/index.js
165
+ - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/mocks/MockForemanTableIndexPage.js
221
166
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksPageActions.js
222
167
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksPageHelpers.js
223
168
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksPageSelectors.js
@@ -225,31 +170,6 @@ files:
225
170
  - webpack/ForemanWebhooks/Routes/Webhooks/__tests__/WebhooksPageSelectors.test.js
226
171
  - webpack/ForemanWebhooks/Routes/Webhooks/__tests__/__snapshots__/WebhooksPageSelectors.test.js.snap
227
172
  - webpack/ForemanWebhooks/Routes/Webhooks/constants.js
228
- - webpack/__mocks__/foremanReact/Root/Context/ForemanContext.js
229
- - webpack/__mocks__/foremanReact/common/HOC.js
230
- - webpack/__mocks__/foremanReact/common/I18n.js
231
- - webpack/__mocks__/foremanReact/common/helpers.js
232
- - webpack/__mocks__/foremanReact/common/urlHelpers.js
233
- - webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalActions.js
234
- - webpack/__mocks__/foremanReact/components/ForemanModal/ForemanModalHooks.js
235
- - webpack/__mocks__/foremanReact/components/ForemanModal/index.js
236
- - webpack/__mocks__/foremanReact/components/Layout/LayoutActions.js
237
- - webpack/__mocks__/foremanReact/components/Loading/Loading.js
238
- - webpack/__mocks__/foremanReact/components/Loading/index.js
239
- - webpack/__mocks__/foremanReact/components/PF4/TableIndexPage/TableIndexPage.js
240
- - webpack/__mocks__/foremanReact/components/Pagination/index.js
241
- - webpack/__mocks__/foremanReact/components/common/ActionButtons/ActionButtons.js
242
- - webpack/__mocks__/foremanReact/components/common/EmptyState.js
243
- - webpack/__mocks__/foremanReact/components/common/forms/ForemanForm.js
244
- - webpack/__mocks__/foremanReact/components/common/forms/FormField.js
245
- - webpack/__mocks__/foremanReact/components/common/table.js
246
- - webpack/__mocks__/foremanReact/constants.js
247
- - webpack/__mocks__/foremanReact/history.js
248
- - webpack/__mocks__/foremanReact/redux/API/APISelectors.js
249
- - webpack/__mocks__/foremanReact/redux/API/index.js
250
- - webpack/__mocks__/foremanReact/redux/actions/common/forms.js
251
- - webpack/__mocks__/foremanReact/redux/actions/toasts.js
252
- - webpack/__mocks__/foremanReact/routes/common/PageLayout/PageLayout.js
253
173
  - webpack/index.js
254
174
  - webpack/routes_index.js
255
175
  - webpack/test_setup.js
@@ -265,14 +185,17 @@ required_ruby_version: !ruby/object:Gem::Requirement
265
185
  requirements:
266
186
  - - ">="
267
187
  - !ruby/object:Gem::Version
268
- version: 2.7.0
188
+ version: '3.0'
189
+ - - "<"
190
+ - !ruby/object:Gem::Version
191
+ version: '4'
269
192
  required_rubygems_version: !ruby/object:Gem::Requirement
270
193
  requirements:
271
194
  - - ">="
272
195
  - !ruby/object:Gem::Version
273
196
  version: '0'
274
197
  requirements: []
275
- rubygems_version: 4.0.6
198
+ rubygems_version: 4.0.10
276
199
  specification_version: 4
277
200
  summary: Configure webhooks for Foreman.
278
201
  test_files:
@@ -289,11 +212,10 @@ test_files:
289
212
  - test/models/webhook_test.rb
290
213
  - test/test_plugin_helper.rb
291
214
  - test/unit/foreman_webhooks/webhook_service_test.rb
292
- - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/Components/__tests__/FieldConstructor.test.js
293
215
  - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookForm/__tests__/WebhookForm.test.js
294
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/Formatters/__tests__/enabledCellFormatter.test.js
295
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/Components/__tests__/EnabledCell.test.js
296
- - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/Components/WebhooksTable/__tests__/WebhooksTable.test.js
216
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/actionCellFormatter.test.js
217
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/enabledCellFormatter.test.js
218
+ - webpack/ForemanWebhooks/Routes/Webhooks/Components/WebhookTable/Components/Formatters/__tests__/nameToEditFormatter.test.js
297
219
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/WebhooksIndexPage.fixtures.js
298
220
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/WebhooksIndexPage.test.js
299
221
  - webpack/ForemanWebhooks/Routes/Webhooks/WebhooksIndexPage/__tests__/integration.test.js