-
Gradle and JUnit example
In Gradle, you can declare the JUnit dependency like this:
2019-08-17【[Java]】
阅读更多 -
Hamcrest How to assertThat check null value?
Try to check null value with the Hamcrest assertThat assertion, but no idea how?
2019-08-17【[Java]】
阅读更多 -
JUnit How to test a List
First, exclude the JUnit bundled copy of hamcrest-core, and include the useful hamcrest-library, it contains many useful methods to test the List data type.
2019-08-17【[Java]】
阅读更多 -
JUnit How to test a Map
Forget about JUnit assertEquals(), to test a Map, uses the more expressive IsMapContaining class from hamcrest-library.jar
2019-08-17【[Java]】
阅读更多 -
JUnit Assert if a property exists in a class
Includes hamcrest-library and test the class property and its value with hasProperty() :
2019-08-17【[Java]】
阅读更多 -
MySQL Backup and restore a database or table
In this tutorial we will show you how to use backup and restore a MySQL database or tables.
2019-08-17【[Java]】
阅读更多 -
Spring Boot file upload example Ajax and REST
This article shows you how to upload files in Spring Boot web application (REST structure), using Ajax requests.
2019-08-11【[Java]】
阅读更多 -
cURL Post JSON data to Spring REST
This article shows you how to use cURL command to POST JSON data to a Spring REST API.
2019-08-11【[Java]】
阅读更多 -
cURL POST request examples
Some cURL POST request examples for self reference.
2019-08-11【[Java]】
阅读更多 -
Spring Boot Ajax example
This article will show you how to use jQuery.ajax to send a HTML form request to a Spring REST API and return a JSON response.
2019-08-11【[Java]】
阅读更多 -
Spring REST API Validation
In Spring MVC, just annotate a @Valid on the @RequestBody to fire the validation process.
2019-08-11【[Java]】
阅读更多 -
ElasticSearch Hello World Example
ElasticSearch is an Open-source Enterprise REST based Real-time Search and Analytics Engine. It’s core Search Functionality is built using Apache Lucene, but supports many other features.
2019-08-11【[Java]】
阅读更多 -
Spring REST Hello World Example
In this article, we will show you how to develop a Spring Boot REST style web service to handle CRUD operations from a H2 In-memory database.
2019-08-11【[Java]】
阅读更多 -
Spring REST Validation Example
In this article, we will enhance the previous Spring REST Hello World example, by adding bean validation and custom validator.
2019-08-11【[Java]】
阅读更多 -
Spring REST Error Handling Example
In this article, we will show you error handling in Spring Boot REST application.
2019-08-11【[Java]】
阅读更多