mirror of
https://github.com/scm-manager/scm-manager.git
synced 2025-11-09 15:05:44 +01:00
Rename media type
This commit is contained in:
@@ -238,7 +238,7 @@ public class RepositoryPermissionRootResourceTest extends RepositoryTestBase {
|
||||
MockHttpRequest request = MockHttpRequest
|
||||
.post("/" + RepositoryRootResource.REPOSITORIES_PATH_V2 + PATH_OF_ALL_PERMISSIONS)
|
||||
.content(permissionJson.getBytes())
|
||||
.contentType(VndMediaType.PERMISSION);
|
||||
.contentType(VndMediaType.REPOSITORY_PERMISSION);
|
||||
MockHttpResponse response = new MockHttpResponse();
|
||||
|
||||
dispatcher.invoke(request, response);
|
||||
@@ -250,7 +250,7 @@ public class RepositoryPermissionRootResourceTest extends RepositoryTestBase {
|
||||
request = MockHttpRequest
|
||||
.post("/" + RepositoryRootResource.REPOSITORIES_PATH_V2 + PATH_OF_ALL_PERMISSIONS)
|
||||
.content(permissionJson.getBytes())
|
||||
.contentType(VndMediaType.PERMISSION);
|
||||
.contentType(VndMediaType.REPOSITORY_PERMISSION);
|
||||
response = new MockHttpResponse();
|
||||
|
||||
dispatcher.invoke(request, response);
|
||||
@@ -430,7 +430,7 @@ public class RepositoryPermissionRootResourceTest extends RepositoryTestBase {
|
||||
HttpRequest request = MockHttpRequest
|
||||
.create(entry.method, "/" + RepositoryRootResource.REPOSITORIES_PATH_V2 + entry.path)
|
||||
.content(entry.content)
|
||||
.contentType(VndMediaType.PERMISSION);
|
||||
.contentType(VndMediaType.REPOSITORY_PERMISSION);
|
||||
dispatcher.invoke(request, response);
|
||||
log.info("Test the Request :{}", entry);
|
||||
assertThat(response.getStatus())
|
||||
|
||||
@@ -124,8 +124,8 @@ public class GitLfsITCase {
|
||||
String permissionsUrl = repository.getLinks().getLinkBy("permissions").get().getHref();
|
||||
IntegrationTestUtil.createResource(adminClient, URI.create(permissionsUrl))
|
||||
.accept("*/*")
|
||||
.type(VndMediaType.PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"type\":\"WRITE\"}");
|
||||
.type(VndMediaType.REPOSITORY_PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"verbs\":[\"*\"]}");
|
||||
|
||||
ScmClient client = new ScmClient(trillian.getId(), "secret123");
|
||||
|
||||
@@ -165,8 +165,8 @@ public class GitLfsITCase {
|
||||
String permissionsUrl = repository.getLinks().getLinkBy("permissions").get().getHref();
|
||||
IntegrationTestUtil.createResource(adminClient, URI.create(permissionsUrl))
|
||||
.accept("*/*")
|
||||
.type(VndMediaType.PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"type\":\"READ\"}");
|
||||
.type(VndMediaType.REPOSITORY_PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"verbs\":[\"read\"]}");
|
||||
|
||||
ScmClient client = new ScmClient(trillian.getId(), "secret123");
|
||||
uploadAndDownload(client);
|
||||
@@ -186,8 +186,8 @@ public class GitLfsITCase {
|
||||
String permissionsUrl = repository.getLinks().getLinkBy("permissions").get().getHref();
|
||||
IntegrationTestUtil.createResource(adminClient, URI.create(permissionsUrl))
|
||||
.accept("*/*")
|
||||
.type(VndMediaType.PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"type\":\"READ\"}");
|
||||
.type(VndMediaType.REPOSITORY_PERMISSION)
|
||||
.post(ClientResponse.class, "{\"name\": \""+ trillian.getId() +"\", \"verbs\":[\"read\"]}");
|
||||
|
||||
// upload data as admin
|
||||
String data = UUID.randomUUID().toString();
|
||||
|
||||
Reference in New Issue
Block a user