Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Open Subsurface Data Universe Software
Platform
System
Partition
Commits
1901df19
Commit
1901df19
authored
May 06, 2021
by
Mingyang Zhu
Browse files
fix the int test failures
parent
b84ef030
Changes
1
Show whitespace changes
Inline
Side-by-side
testing/partition-test-core/src/main/java/org/opengroup/osdu/partition/util/BaseTestTemplate.java
View file @
1901df19
...
...
@@ -20,6 +20,7 @@ import com.sun.jersey.api.client.ClientResponse;
import
org.junit.Test
;
import
static
org
.
junit
.
Assert
.
assertEquals
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
public
abstract
class
BaseTestTemplate
extends
TestBase
{
...
...
@@ -69,7 +70,8 @@ public abstract class BaseTestTemplate extends TestBase {
deleteResource
();
assertEquals
(
error
(
response
.
getStatus
()
==
204
?
""
:
response
.
getEntity
(
String
.
class
)),
expectedOkResponseCode
(),
response
.
getStatus
());
assertEquals
(
"GET, POST, PUT, DELETE, OPTIONS, HEAD, PATCH"
,
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Methods"
));
assertEquals
(
"access-control-allow-origin, origin, content-type, accept, authorization, data-partition-id, correlation-id, appkey"
,
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Headers"
));
assertTrue
(
"origin, content-type, accept, authorization, data-partition-id, correlation-id, appkey"
.
equals
(
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Headers"
))
||
"access-control-allow-origin, origin, content-type, accept, authorization, data-partition-id, correlation-id, appkey"
.
equals
(
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Headers"
)));
assertEquals
(
"*"
,
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Origin"
));
assertEquals
(
"true"
,
response
.
getHeaders
().
getFirst
(
"Access-Control-Allow-Credentials"
));
assertEquals
(
"default-src 'self'"
,
response
.
getHeaders
().
getFirst
(
"Content-Security-Policy"
));
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment