Commit 452d0a4e authored by Jose Ivan Vargas's avatar Jose Ivan Vargas

Merge branch 'revert-365bcd8d' into 'master'

Revert "Merge branch 'add_standard_field_into_payload' into 'master'"

See merge request gitlab-org/gitlab!40162
parents f9087286 62d09256
...@@ -44,7 +44,6 @@ export const createPolicy = ({ state, commit }, { environmentId, policy }) => { ...@@ -44,7 +44,6 @@ export const createPolicy = ({ state, commit }, { environmentId, policy }) => {
.post(state.policiesEndpoint, { .post(state.policiesEndpoint, {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
is_standard: policy.isStandard,
}) })
.then(({ data }) => { .then(({ data }) => {
commit(types.RECEIVE_CREATE_POLICY_SUCCESS, data); commit(types.RECEIVE_CREATE_POLICY_SUCCESS, data);
...@@ -72,7 +71,6 @@ export const updatePolicy = ({ state, commit }, { environmentId, policy }) => { ...@@ -72,7 +71,6 @@ export const updatePolicy = ({ state, commit }, { environmentId, policy }) => {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
enabled: policy.isEnabled, enabled: policy.isEnabled,
is_standard: policy.isStandard,
}) })
.then(({ data }) => { .then(({ data }) => {
commit(types.RECEIVE_UPDATE_POLICY_SUCCESS, { commit(types.RECEIVE_UPDATE_POLICY_SUCCESS, {
......
---
title: Revert Merge branch add_standard_field_into_payload into master
merge_request: 40162
author:
type: changed
...@@ -6,10 +6,10 @@ exports[`NetworkPolicyList component renders policies table 1`] = ` ...@@ -6,10 +6,10 @@ exports[`NetworkPolicyList component renders policies table 1`] = `
<table <table
aria-busy="false" aria-busy="false"
aria-colcount="3" aria-colcount="3"
aria-describedby="__BVID__151__caption_" aria-describedby="__BVID__143__caption_"
aria-multiselectable="false" aria-multiselectable="false"
class="table b-table gl-table table-hover b-table-stacked-md b-table-selectable b-table-select-single" class="table b-table gl-table table-hover b-table-stacked-md b-table-selectable b-table-select-single"
id="__BVID__151" id="__BVID__143"
role="table" role="table"
> >
<!----> <!---->
...@@ -92,47 +92,6 @@ exports[`NetworkPolicyList component renders policies table 1`] = ` ...@@ -92,47 +92,6 @@ exports[`NetworkPolicyList component renders policies table 1`] = `
2 months ago 2 months ago
</div>
</td>
</tr>
<tr
aria-selected="false"
class=""
role="row"
tabindex="0"
>
<td
aria-colindex="1"
class=""
data-label="Name"
role="cell"
>
<div>
cilium_policy
</div>
</td>
<td
aria-colindex="2"
class=""
data-label="Status"
role="cell"
>
<div>
Enabled
</div>
</td>
<td
aria-colindex="3"
class=""
data-label="Last modified"
role="cell"
>
<div>
</div> </div>
</td> </td>
</tr> </tr>
......
...@@ -38,28 +38,6 @@ spec: ...@@ -38,28 +38,6 @@ spec:
project: myproject`, project: myproject`,
creation_timestamp: '2020-04-14T00:08:30Z', creation_timestamp: '2020-04-14T00:08:30Z',
is_enabled: true, is_enabled: true,
is_standard: true,
},
{
name: 'cilium_policy',
namespace: 'production',
manifest: `---
apiVersion: cilium.io/v2
kind: CiliumNetworkPolicy
metadata:
name: cilium_policy
namespace: production
spec:
endpointSelector:
matchLabels:
role: db
ingress:
- fromEndpoints:
- matchLabels:
project: myproject`,
created_timestamp: '2020-04-15T00:08:30Z',
is_enabled: true,
is_standard: false,
}, },
]; ];
......
...@@ -19,7 +19,7 @@ describe('Network Policy actions', () => { ...@@ -19,7 +19,7 @@ describe('Network Policy actions', () => {
let state; let state;
let mock; let mock;
const environmentId = 3; const environmentId = 3;
const policy = { name: 'policy', manifest: 'foo', isEnabled: true, isStandard: true }; const policy = { name: 'policy', manifest: 'foo', isEnabled: true };
beforeEach(() => { beforeEach(() => {
state = getInitialState(); state = getInitialState();
...@@ -138,7 +138,7 @@ describe('Network Policy actions', () => { ...@@ -138,7 +138,7 @@ describe('Network Policy actions', () => {
}); });
describe('createPolicy', () => { describe('createPolicy', () => {
const createdPolicy = { name: 'policy', manifest: 'bar', isEnabled: true, isStandard: true }; const createdPolicy = { name: 'policy', manifest: 'bar', isEnabled: true };
describe('on success', () => { describe('on success', () => {
beforeEach(() => { beforeEach(() => {
...@@ -146,7 +146,6 @@ describe('Network Policy actions', () => { ...@@ -146,7 +146,6 @@ describe('Network Policy actions', () => {
.onPost(networkPoliciesEndpoint, { .onPost(networkPoliciesEndpoint, {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
is_standard: true,
}) })
.replyOnce(httpStatus.OK, createdPolicy); .replyOnce(httpStatus.OK, createdPolicy);
}); });
...@@ -177,7 +176,6 @@ describe('Network Policy actions', () => { ...@@ -177,7 +176,6 @@ describe('Network Policy actions', () => {
.onPost(networkPoliciesEndpoint, { .onPost(networkPoliciesEndpoint, {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
is_standard: true,
}) })
.replyOnce(500, error); .replyOnce(500, error);
}); });
...@@ -242,7 +240,7 @@ describe('Network Policy actions', () => { ...@@ -242,7 +240,7 @@ describe('Network Policy actions', () => {
}); });
describe('updatePolicy', () => { describe('updatePolicy', () => {
const updatedPolicy = { name: 'policy', manifest: 'bar', isEnabled: true, isStandard: true }; const updatedPolicy = { name: 'policy', manifest: 'bar', isEnabled: true };
describe('on success', () => { describe('on success', () => {
beforeEach(() => { beforeEach(() => {
...@@ -251,7 +249,6 @@ describe('Network Policy actions', () => { ...@@ -251,7 +249,6 @@ describe('Network Policy actions', () => {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
enabled: policy.isEnabled, enabled: policy.isEnabled,
is_standard: policy.isStandard,
}) })
.replyOnce(httpStatus.OK, updatedPolicy); .replyOnce(httpStatus.OK, updatedPolicy);
}); });
...@@ -281,7 +278,6 @@ describe('Network Policy actions', () => { ...@@ -281,7 +278,6 @@ describe('Network Policy actions', () => {
environment_id: environmentId, environment_id: environmentId,
manifest: policy.manifest, manifest: policy.manifest,
enabled: policy.isEnabled, enabled: policy.isEnabled,
is_standard: policy.isStandard,
}) })
.replyOnce(500, error); .replyOnce(500, error);
}); });
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment