📝 overworked templates

This commit is contained in:
Niels Lohmann 2017-10-29 16:32:23 +01:00
parent 87df1d6708
commit 6d2981db82
No known key found for this signature in database
GPG key ID: 7F3CEA63AE251B69
3 changed files with 36 additions and 24 deletions

View file

@ -22,18 +22,24 @@ Clearly describe the issue:
- If you propose a change or addition, try to give an **example** how the improved code could look like or how to use it.
- If you found a compilation error, please tell us which **compiler** (version and operating system) you used and paste the (relevant part of) the error messages to the ticket.
Please stick to the [issue template](https://github.com/nlohmann/json/blob/develop/.github/ISSUE_TEMPLATE.md) if possible.
## Files to change
There are currently two files which need to be edited:
1. [`src/json.hpp`](https://github.com/nlohmann/json/blob/master/src/json.hpp)
2. [`test/src/unit.cpp`](https://github.com/nlohmann/json/blob/master/test/unit.cpp) - This contains the [Catch](https://github.com/philsquared/Catch) unit tests which currently cover [100 %](https://coveralls.io/github/nlohmann/json) of the library's code.
2. [`test/src/unit-*.cpp`](https://github.com/nlohmann/json/tree/develop/test/src) - These files contain the [Catch](https://github.com/philsquared/Catch) unit tests which currently cover [100 %](https://coveralls.io/github/nlohmann/json) of the library's code.
If you add or change a feature, please also add a unit test to this file. The unit tests can be compiled and executed with
```sh
make check
$ mkdir build
$ cd build
$ cmake ..
$ cmake --build .
$ ctest
```
The test cases are also executed with several different compilers on [Travis](https://travis-ci.org/nlohmann/json) once you open a pull request.

22
.github/ISSUE_TEMPLATE.md vendored Normal file
View file

@ -0,0 +1,22 @@
**Bug Report**
- What is the issue you have?
- Please describe the steps to reproduce the issue. Can you provide a small but working code example?
- What is the expected behavior?
- And what is the actual behavior instead?
- Which compiler and operating system are you using? Is it a [supported compiler](https://github.com/nlohmann/json#supported-compilers)?
- Did you use a released version of the library or the version from the `develop` branch?
- If you experience a compilation error: can you [compile and run the unit tests](https://github.com/nlohmann/json#execute-unit-tests)?
**Feature Request**
- Describe the feature in as much detail as possible.
- Include sample usage where appropriate.

View file

@ -1,28 +1,12 @@
[Describe your pull request here. Please read the text below the line, and make sure you follow the checklist.]
## Files to change
* * *
There are currently two files which need to be edited:
## Pull request checklist
1. [`src/json.hpp`](https://github.com/nlohmann/json/blob/master/src/json.hpp)
2. [`test/src/unit.cpp`](https://github.com/nlohmann/json/blob/master/test/unit.cpp) - This contains the [Catch](https://github.com/philsquared/Catch) unit tests which currently cover [100 %](https://coveralls.io/github/nlohmann/json) of the library's code.
If you add or change a feature, please also add a unit test to this file. The unit tests can be compiled and executed with
```sh
$ mkdir build
$ cd build
$ cmake ..
$ make
$ ctest
```
The test cases are also executed with several different compilers on [Travis](https://travis-ci.org/nlohmann/json) once you open a pull request.
## Note
- If you open a pull request, the code will be automatically tested with [Valgrind](http://valgrind.org)'s Memcheck tool to detect memory leaks. Please be aware that the execution with Valgrind _may_ in rare cases yield different behavior than running the code directly. This can result in failing unit tests which run successfully without Valgrind.
- [ ] Changes are described in the pull request, or an [existing issue is referenced](https://github.com/nlohmann/json/issues).
- [ ] The test suite [compiles and runs](https://github.com/nlohmann/json/blob/develop/README.md#execute-unit-tests) without error.
- [ ] [Code coverage](https://coveralls.io/github/nlohmann/json) is 100%. Test cases can be added by editing the [test suite](https://github.com/nlohmann/json/tree/develop/test/src).
## Please don't