Skip to content
This repository was archived by the owner on Dec 19, 2023. It is now read-only.

Commit bd943d8

Browse files
authored
Kotlin example project (#218)
* Move Java Web MVC example * Adjust naming of Java example * Add Kotlin example project * Fix directory traversal
1 parent a0807b6 commit bd943d8

File tree

66 files changed

+4624
-110
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

66 files changed

+4624
-110
lines changed

.travis.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,15 @@ before_install:
1717
-Dpackaging=jar -Dclassifier=test
1818
script:
1919
- mvn install -B -V
20-
- cd spring-auto-restdocs-example
20+
- cd samples
21+
- cd java-webmvc
22+
- mvn verify -B
2123
- ./gradlew check
2224
- cd ..
25+
- cd kotlin-webmvc
26+
- mvn verify -B
27+
- cd ..
28+
- cd ..
2329
after_success:
2430
- test "$TRAVIS_BRANCH" = "master"
2531
&& test "$TRAVIS_PULL_REQUEST" = "false"

pom.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@
1515
<modules>
1616
<module>spring-auto-restdocs-json-doclet</module>
1717
<module>spring-auto-restdocs-core</module>
18-
<module>spring-auto-restdocs-example</module>
1918
<module>spring-auto-restdocs-docs</module>
2019
<module>spring-auto-restdocs-dokka-json</module>
2120
</modules>

samples/java-webmvc/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Java Web MVC Example
2+
3+
This project shows the use of Spring Auto REST Docs with Web MVC in a Java 8 project.
File renamed without changes.

spring-auto-restdocs-example/generated-docs/index.html renamed to samples/java-webmvc/generated-docs/index.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1129,7 +1129,7 @@ <h4 id="_example_request"><a class="anchor" href="#_example_request"></a><a clas
11291129
<div class="content">
11301130
<pre class="highlightjs highlight"><code class="language-bash hljs" data-lang="bash">$ curl 'http://localhost:8080/items' -i -X POST \
11311131
-H 'Content-Type: application/json' \
1132-
-H 'Authorization: Bearer 7c73f031-9208-46ed-ba75-9af975a05c2d' \
1132+
-H 'Authorization: Bearer e9f9040c-925f-482b-8bf6-3601a1693407' \
11331133
-d '{"description":"Hot News"}'</code></pre>
11341134
</div>
11351135
</div>
@@ -1366,7 +1366,7 @@ <h4 id="_example_request_2"><a class="anchor" href="#_example_request_2"></a><a
13661366
<div class="content">
13671367
<pre class="highlightjs highlight"><code class="language-bash hljs" data-lang="bash">$ curl 'http://localhost:8080/items/1' -i -X PUT \
13681368
-H 'Content-Type: application/json' \
1369-
-H 'Authorization: Bearer 7c73f031-9208-46ed-ba75-9af975a05c2d' \
1369+
-H 'Authorization: Bearer e9f9040c-925f-482b-8bf6-3601a1693407' \
13701370
-d '{"description":"Hot News"}'</code></pre>
13711371
</div>
13721372
</div>
@@ -1472,7 +1472,7 @@ <h4 id="_example_request_3"><a class="anchor" href="#_example_request_3"></a><a
14721472
<div class="listingblock">
14731473
<div class="content">
14741474
<pre class="highlightjs highlight"><code class="language-bash hljs" data-lang="bash">$ curl 'http://localhost:8080/items/1' -i -X DELETE \
1475-
-H 'Authorization: Bearer 7c73f031-9208-46ed-ba75-9af975a05c2d'</code></pre>
1475+
-H 'Authorization: Bearer e9f9040c-925f-482b-8bf6-3601a1693407'</code></pre>
14761476
</div>
14771477
</div>
14781478
</div>
@@ -1968,8 +1968,8 @@ <h4 id="_example_response_5"><a class="anchor" href="#_example_response_5"></a><
19681968
"unpaged" : false
19691969
},
19701970
"total" : 1,
1971-
"totalPages" : 1,
19721971
"last" : true,
1972+
"totalPages" : 1,
19731973
"totalElements" : 1,
19741974
"first" : true,
19751975
"sort" : {
@@ -2554,7 +2554,7 @@ <h4 id="_example_request_response_3"><a class="anchor" href="#_example_request_r
25542554
</div>
25552555
<div id="footer">
25562556
<div id="footer-text">
2557-
Last updated 2018-01-30 18:01:20 CET
2557+
Last updated 2018-01-16 08:44:06 CET
25582558
</div>
25592559
</div>
25602560
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/github.min.css">

spring-auto-restdocs-example/gradle/wrapper/gradle-wrapper.jar renamed to samples/java-webmvc/gradle/wrapper/gradle-wrapper.jar

File renamed without changes.

spring-auto-restdocs-example/gradle/wrapper/gradle-wrapper.properties renamed to samples/java-webmvc/gradle/wrapper/gradle-wrapper.properties

File renamed without changes.

0 commit comments

Comments
 (0)