mirror of
https://gitee.com/dcren/initializr.git
synced 2025-09-18 17:48:14 +08:00
Fix initial Java migration
This commit fixes several issues with the initial java migration. On MacOS, the name of the temp directory can be `T` and the new tgz API requires a parent folder whose name has at least 3 characters. The Selenium tests require a more precise element to show the advanced section. The integration tests were generation the docs snippet on the wrong accept header.
This commit is contained in:
@@ -169,9 +169,6 @@ public class MainControllerIntegrationTests
|
||||
|
||||
@Test
|
||||
public void metadataWithV2AcceptHeader() {
|
||||
getRequests().setFields("_links.maven-project", "dependencies.values[0]",
|
||||
"type.values[0]", "javaVersion.values[0]", "packaging.values[0]",
|
||||
"bootVersion.values[0]", "language.values[0]");
|
||||
ResponseEntity<String> response = invokeHome(null,
|
||||
"application/vnd.initializr.v2+json");
|
||||
validateMetadata(response, InitializrMetadataVersion.V2.getMediaType(), "2.0.0",
|
||||
@@ -180,6 +177,9 @@ public class MainControllerIntegrationTests
|
||||
|
||||
@Test
|
||||
public void metadataWithCurrentAcceptHeader() {
|
||||
getRequests().setFields("_links.maven-project", "dependencies.values[0]",
|
||||
"type.values[0]", "javaVersion.values[0]", "packaging.values[0]",
|
||||
"bootVersion.values[0]", "language.values[0]");
|
||||
ResponseEntity<String> response = invokeHome(null,
|
||||
"application/vnd.initializr.v2.1+json");
|
||||
assertThat(response.getHeaders().getFirst(HttpHeaders.ETAG), not(nullValue()));
|
||||
|
@@ -436,7 +436,8 @@ class HomePage {
|
||||
}
|
||||
|
||||
public void advanced() {
|
||||
form.findElement(By.cssSelector(".tofullversion")).click();
|
||||
form.findElement(By.cssSelector(".tofullversion"))
|
||||
.findElement(By.tagName("a")).click();
|
||||
}
|
||||
|
||||
public void simple() {
|
||||
|
Reference in New Issue
Block a user