Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
N
Notification
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
OSDU
OSDU Data Platform
System
Notification
Commits
a1650427
Commit
a1650427
authored
2 years ago
by
Manish Jangid
Browse files
Options
Downloads
Patches
Plain Diff
Removed test validations on cors response headers
parent
2d8e5e13
No related branches found
No related tags found
1 merge request
!349
Removed test validations on cors response headers
Pipeline
#167109
failed
2 years ago
Stage: build
Stage: coverage
Stage: containerize
Stage: scan
Stage: deploy
Stage: integration
Changes
1
Pipelines
3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
testing/notification-test-aws/src/test/java/org/opengroup/osdu/notification/api/TestPubsubEndpointHMAC.java
+23
-0
23 additions, 0 deletions
...engroup/osdu/notification/api/TestPubsubEndpointHMAC.java
with
23 additions
and
0 deletions
testing/notification-test-aws/src/test/java/org/opengroup/osdu/notification/api/TestPubsubEndpointHMAC.java
+
23
−
0
View file @
a1650427
...
...
@@ -14,6 +14,7 @@
package
org.opengroup.osdu.notification.api
;
import
static
org
.
junit
.
Assert
.
assertEquals
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
import
org.junit.After
;
import
org.junit.AfterClass
;
...
...
@@ -132,4 +133,26 @@ public class TestPubsubEndpointHMAC extends PubsubEndpointHMACTests {
awssubscriptionService
.
delete
(
subscriptionId
);
}
@Override
@Test
public
void
should_return20X_when_usingCredentialsWithOpsPermission
()
throws
Exception
{
createResource
();
try
{
ClientResponse
response
=
descriptor
.
run
(
getArg
(),
testUtils
.
getOpsToken
());
assertEquals
(
error
(
response
.
getStatus
()
==
204
?
""
:
response
.
getEntity
(
String
.
class
)),
expectedOkResponseCode
(),
response
.
getStatus
());
assertEquals
(
"DENY"
,
response
.
getHeaders
().
getFirst
(
"X-Frame-Options"
));
assertEquals
(
"1; mode=block"
,
response
.
getHeaders
().
getFirst
(
"X-XSS-Protection"
));
assertEquals
(
"nosniff"
,
response
.
getHeaders
().
getFirst
(
"X-Content-Type-Options"
));
assertEquals
(
"no-cache, no-store, must-revalidate"
,
response
.
getHeaders
().
getFirst
(
"Cache-Control"
));
assertEquals
(
"default-src 'self'"
,
response
.
getHeaders
().
getFirst
(
"Content-Security-Policy"
));
assertTrue
(
response
.
getHeaders
().
get
(
"Strict-Transport-Security"
).
get
(
0
).
contains
(
"max-age=31536000"
));
assertTrue
(
response
.
getHeaders
().
get
(
"Strict-Transport-Security"
).
get
(
0
).
contains
(
"includeSubDomains"
));
assertEquals
(
"0"
,
response
.
getHeaders
().
getFirst
(
"Expires"
));
}
finally
{
deleteResource
();
}
}
}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Manish Jangid
@manish_jangid
mentioned in commit
2dcfd5a0
·
2 years ago
mentioned in commit
2dcfd5a0
mentioned in commit 2dcfd5a02c0ba75cb777c9a912ef1e7b565760d2
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment