Polish template

I like Spring Initializr (numerous references on twitter) and it feels
odd to me to put the address of the web site on the web site itself since
we want to push for custom deployments (that would have a different URL
obviously).

Also the "Quick add dependencies" can be simply named "Dependencies"; it
is consistent with the project metadata section as well.

Also, the template does not have any reference to 'install.sh' so any
test relying on the presence of that link now fails. Replaced them with
a different reference.

See gh-145
This commit is contained in:
Stephane Nicoll
2015-09-29 08:35:23 +02:00
parent 431d2a5e4d
commit 8187ced611
3 changed files with 10 additions and 10 deletions

View File

@@ -1,7 +1,7 @@
<!DOCTYPE html>
<html lang="en">
<head>
<title>start.spring.io</title>
<title>Spring Initializr</title>
<link href="//fonts.googleapis.com/css?family=Varela+Round|Montserrat:400,700" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="/css/bootstrap.min.css"/>
<link rel="stylesheet" href="/css/bootstrap-theme.min.css"/>
@@ -14,9 +14,9 @@
<div class="row">
<div class="start-header">
<div class="container">
<h1>start.spring.io</h1>
<h1>Spring Initializr</h1>
<p>Generate your Spring Boot project in seconds!</p>
<p>Bootstrap your application now</p>
</div>
<a href="https://github.com/spring-io/initializr" target="_blank">
<img style="position: absolute; top: 0; right: 0; border: 0;"
@@ -106,7 +106,7 @@
</div>
</div>
<div class="row">
<h2>Quick add dependencies</h2>
<h2>Dependencies</h2>
<p>Add Spring Boot Starters and dependencies to your application</p>
@@ -121,7 +121,7 @@
</div>
</div>
<p class="text-center">
Or check out <a href="#starters-list">the complete list of Dependencies.</a>
Or check out <a href="#starters-list">the complete list of dependencies.</a>
</p>
</div>
<div class="form-group col-md-6 col-sm-12">

View File

@@ -20,6 +20,7 @@ import org.junit.Test
import org.springframework.http.HttpEntity
import org.springframework.http.HttpStatus
import org.springframework.http.ResponseEntity
import org.springframework.test.context.ActiveProfiles
import static org.junit.Assert.*
@@ -40,8 +41,10 @@ class MainControllerEnvIntegrationTests extends AbstractInitializrControllerInte
@Test
void doNotForceSsl() {
def body = htmlHome()
assertTrue "Force SSL should be disabled", body.contains("http://localhost:$port/install.sh")
ResponseEntity<String> response = invokeHome('curl/1.2.4', "*/*")
String body = response.getBody()
assertTrue "Must not force https", body.contains("http://localhost:$port/")
assertFalse "Must not force https", body.contains('https://')
}
@Test

View File

@@ -34,7 +34,6 @@ import static org.hamcrest.CoreMatchers.allOf
import static org.hamcrest.CoreMatchers.containsString
import static org.hamcrest.core.IsNot.not
import static org.junit.Assert.assertEquals
import static org.junit.Assert.assertFalse
import static org.junit.Assert.assertNotNull
import static org.junit.Assert.assertThat
import static org.junit.Assert.assertTrue
@@ -364,8 +363,6 @@ class MainControllerIntegrationTests extends AbstractInitializrControllerIntegra
void homeIsForm() {
def body = htmlHome()
assertTrue "Wrong body:\n$body", body.contains('action="/starter.zip"')
assertTrue "Must force https", body.contains("https://localhost:$port/install.sh")
assertFalse "Must force https", body.contains('http://')
}
@Test