Commit Graph

104 Commits

Author SHA1 Message Date
Andy Wilkinson
6e7dc7c95f Merge branch '1.2.x' 2018-08-08 09:57:58 +01:00
Andy Wilkinson
39a5198c3b Upgrade the Grails sample to Grails 3.3.x and Gradle 4.9
Closes gh-540
2018-08-08 09:57:15 +01:00
Andy Wilkinson
8055319b89 Use Bean Validations @NotBlank rather than Hibernate Validator's
Closes gh-536
2018-08-01 14:12:40 +01:00
Andy Wilkinson
857e29a3c9 Polish "Move away from deprecated RestAssuredPreprocessors.modifyUris()"
See gh-532
2018-08-01 14:01:10 +01:00
Nik Gorylenko
d8070aed46 Move away from deprecated RestAssuredPreprocessors.modifyUris()
Closes gh-532
2018-08-01 13:59:59 +01:00
Andy Wilkinson
6d6909bfeb Update the samples to use 2.0.3 snapshots 2018-07-19 16:57:38 +01:00
Andy Wilkinson
8bb460170c Update the samples to use 1.2.6 snapshots 2018-07-19 12:51:24 +01:00
Andy Wilkinson
99ee889708 Make JUnit Jupiter extension stateless so it can be used in parallel
Previously, REST Docs' JUnit Jupiter extension,
RestDocumentationExtension, stored its own state. Since the code
was written I have learned that this isn't recommended and that the
extension context's store should be used instead. Up until now, we'd
got away with the extension being stateful, but the introduction of
parallel test execution has highlighted the problem.

This commit updates RestDocumentationExtension to use the store from
the execution context rather than storing its own state. An unwanted,
but necessary, side-effect of this is that RestDocumentationExtension
itself no longer implements RestDocumentationContextProvider and,
instead, returns a new type rather than itself when asked to resolve
the provider. This is technically a breaking API change, but users
will be unaffected if they have followed the recommended and
documented approach of injecting RestDocumentationContextProvider.

Closes gh-520
2018-06-26 10:21:30 +01:00
이동욱
e7c59fdaf6 Configure bootJar task to add documentation to Spring Boot fat jar
Closes gh-521
2018-06-26 09:21:16 +01:00
Andy Wilkinson
a1198069be Merge branch '1.2.x' 2018-04-24 08:35:38 +01:00
Andy Wilkinson
1e35e8279c Polish Slate sample's README 2018-04-24 08:35:13 +01:00
Andy Wilkinson
cafd526d86 Update the samples to build against 2.0.2 samples 2018-04-23 17:52:47 +01:00
Andy Wilkinson
a2b62e025a Update samples to use 1.2.5 snapshots 2018-04-04 10:55:02 +01:00
Andy Wilkinson
223d2cc9a4 Try to isolate Grails sample from Bintray outages 2018-03-27 15:29:15 +01:00
Andy Wilkinson
097b38d5c5 Update the Spring Boot-based samples to use 2.0.0.RELEASE
Closes gh-494
2018-03-27 15:16:08 +01:00
Krzysztof Kocel
87fbd10000 Make Slate sample build again
Closes gh-485
2018-03-26 12:56:17 +01:00
Andy Wilkinson
712b5fd9f7 Merge branch '1.2.x' 2018-02-05 12:31:26 +00:00
Jennifer Strater
75bc7e0538 Update the Grails sample to use Grails 3.3 and Gradle 4.4
Closes gh-469
2018-01-02 14:48:03 +00:00
Andy Wilkinson
874bfd119e Update samples to use 1.2.4 snapshots 2017-11-28 09:23:03 +00:00
Andy Wilkinson
bd3d253a2c Upgrade samples to use 2.0.1 snapshots 2017-11-28 08:55:46 +00:00
Johnny Lim
5750babc6f Upgrade to org.asciidoctor.convert 1.5.6
Closes gh-459
2017-11-18 16:30:35 +00:00
Andy Wilkinson
a8169cce0b Upgrade Boot-based samples to Spring Boot 2.0.0.M6
Closes gh-444
2017-11-06 21:18:55 +00:00
Andy Wilkinson
9c9a6f4489 Upgrade REST Assured sample to build with Gradle 4.3
See gh-446
2017-11-06 21:18:25 +00:00
Andy Wilkinson
aedb9a7bab Align with breaking API changes since JUnit 5.0 M4
Closes gh-451
2017-11-06 21:02:00 +00:00
Andy Wilkinson
c7fd07576b Build with Gradle 4.3 where possible
Upgrade the main build and all the Gradle-based samples other than
the Gradle sample to Gradle 4.3.

Closes gh-446
2017-11-06 20:42:36 +00:00
Andy Wilkinson
cfb1fbc85d Add support for using WebFlux's WebTestClient to document an API
Closes gh-384
2017-10-30 09:58:07 +00:00
Andy Wilkinson
d1881c30e2 Update the samples to use the latest snapshots 2017-09-28 06:57:44 +01:00
Johnny Lim
59311292ba Correct the documentation generated by the JUnit 5 sample
Closes gh-408
2017-06-29 12:31:30 +01:00
Andy Wilkinson
0e6e785fb0 Add support for JUnit 5
This commit adds support for JUnit 5 and its Jupiter programming
model. A new Jupiter Extension implementation,
RestDocumentationExtension, is provided. This extension can be applied
to a test class to allow it to use Spring REST Docs to document a
RESTful API.

Closes gh-296
2017-05-19 17:29:12 +02:00
Andy Wilkinson
41d537d06a Raise the minimum supported version of Spring Framework to 5.0
This commit upgrades to Spring Framework 5.0.0.RC1. It also upgrades
the Spring Boot-based samples to use Spring Boot 2.0.0.M1 which
supports Spring Framework 5. Lastly, it upgrades a number of
third-party dependencies to align with Spring Framework 5 and Spring
Boot 2.

Closes gh-386
2017-05-18 16:46:03 +02:00
Andy Wilkinson
a8e1df3fd8 Raise the minimum support version of Java to 8
Closes gh-388
2017-05-18 16:45:27 +02:00
Andy Wilkinson
ce8a296df0 Start work on 2.0 2017-05-16 16:12:02 +01:00
Andy Wilkinson
56a0495288 Update the samples to use the latest snapshots 2017-05-12 20:10:47 +01:00
Andy Wilkinson
88db798b25 Update the dependency versions in the samples to use latest snapshots 2017-05-12 12:35:05 +01:00
Gerrit Meier
419547dcdf Add plugin snapshot repository to Data REST sample
Previously, if the main project hadn't been installed in the local
Maven repository (./gradlew install), rest-notes-spring-data-rest
would fail to build as the plugin dependency,
spring-restdocs-asciidoctor, was not available.

This commit corrects the problem by adding
repo.spring.io/libs-snapshot as a plugin repository in addition to
its existing declaration as a "normal" repository.

Fixes gh-382
Closes gh-383
2017-04-24 13:08:53 +01:00
Andy Wilkinson
1e2f2fdd35 Upgrade Spring Boot-based samples to use 1.5.3.RELEASE
Closes gh-358
2017-04-24 12:59:50 +01:00
Andy Wilkinson
14da4b954a Upgrade main build and Gradle-based samples to Gradle 3.4.1 2017-03-23 11:59:13 +00:00
Andy Wilkinson
78982cf515 Add support for REST Assured 3
Closes gh-262
2017-03-20 21:39:25 +00:00
Johnny Lim
39fabc28d4 Fix typo in value of snippets attribute
Closes gh-369
2017-03-20 09:26:42 +00:00
Andy Wilkinson
58bf231c8a Update the samples to use the new operation macro
Closes gh-362
2017-03-08 12:22:00 +00:00
Andy Wilkinson
ca86e3ad8c Upgrade Slate sample to Slate 1.5
Closes gh-361
2017-03-04 22:13:46 +00:00
Andy Wilkinson
3a0f4ab68e Fix the Slate sample's tests
Closes gh-339
2017-03-04 21:43:12 +00:00
Andy Wilkinson
31ad4b40a0 Upgrade the Grails sample to Grails 3.2.6
Closes gh-357
2017-03-03 16:57:55 +00:00
Andy Wilkinson
1393182182 Upgrade Spring Boot-based samples and integration tests to use 1.4
Closes gh-327
2016-10-28 21:25:30 +01:00
Andy Wilkinson
cbd96f301d Update field snippets to no longer document whole subsection by default
Previously, when a field was documented it would implicitly document
the whole subsection of the payload identified by that field. This
could lead to users inadvertently failing to document part of the
payload. Arguably, this was a bug as it violated REST Docs' principle
of producing accurate, detail documentation. However, fixing it
requires a breaking change as people may also be relying on this
behaviour. A balance needed to be struck so the fix is being made in
a minor release.

This commit introduces a new subsectionWithPath method which returns a
SubsectionDescriptor; a specialisation of FieldDescriptor. Users
that were intentionally relying on the old behaviour will have to
replace some usage of fieldWithPath with subsectionWithPath instead.
Users who were unintentionally relying on the old behaviour will have
to add some additional descriptors produced using fieldWithPath and
will receive more accurate documentation in return.

Closes gh-274
2016-10-28 16:12:07 +01:00
Andy Wilkinson
319bd139fc Polish contribution and rework to use default attribute rather than macro
Rather than introducing a custom macro, this commit opts to implicitly
configure the snippets attribute instead. The attribute is configured
will the path into which snippets are generated, relative to the
directory that contains the Asciidoctor document that is being
rendered.

The samples and documentation have been updated to use the new
spring-restdocs-asciidoctor module and the implicitly configured
snippets attribute.

Closes gh-297
2016-10-21 22:42:11 +01:00
Gerrit Meier
3ac4a1acad Provide a default output directory for snippets based on build tool
Rather than requiring an output directory to be explcitly configured,
a default is now automatically configured based on the build tool
that's being used. When using Gradle, snippets will be generated in
build/generated-snippets. When using Maven, snippets will be
generated in target/generated-snippets.

See gh-297
2016-10-21 22:26:58 +01:00
Andy Wilkinson
f2717363f0 Raise the minimum Spring Framework version to 4.3.x
Closes gh-284
2016-07-26 12:09:20 +01:00
Andy Wilkinson
65571d98dd Revert "Upgrade to Gradle 2.14.1"
This reverts commit 5c74bef194 and
commit 10e421a105.

See gh-283
2016-07-25 18:01:55 +01:00
Andy Wilkinson
10e421a105 Upgrade the samples that use Gradle to 2.14.1 as well
See gh-283
2016-07-25 15:39:12 +01:00