Skip to content

Commit 3fa1aa4

Browse files
committed
Update Readme
1 parent 92f30c5 commit 3fa1aa4

File tree

1 file changed

+24
-34
lines changed

1 file changed

+24
-34
lines changed

README.md

Lines changed: 24 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,35 @@
11
# C++Spec
2-
[![version](https://img.shields.io/badge/version-v0.0.0-blue.svg)]()
2+
[![license](https://img.shields.io/badge/license-MIT-blue)](https://choosealicense.com/licenses/mit/)
33
[![GitHub Action](https://github.com/toroidal-code/cppspec/actions/workflows/test.yml/badge.svg)]() 
44
[![GitHub release](https://img.shields.io/github/release/toroidal-code/cppspec.svg)](https://github.com/toroidal-code/cppspec/releases/latest) 
5-
[![Github Releases](https://img.shields.io/github/downloads/toroidal-code/cppspec/latest/total.svg)]() 
65
[![Documentation Status](https://readthedocs.org/projects/cppspec/badge/?version=latest)](http://cppspec.readthedocs.org/en/latest/?badge=latest)
76

87
A behavior-driven development testing library for C++ with an RSpec-inspired DSL.
98

10-
## Warning! This is pre-release software and may be incomplete, contain bugs, and/or introduce major breaking changes within a short period of time
9+
## Documentation
1110

12-
## Installation ##
13-
14-
C++Spec will be released as a single collated header-file that can be placed in any include path in your project. After that, all features are available via `#include "cppspec.hpp"`.
15-
16-
If you want to use the git repo for development or to integrate it into your own
17-
project as a submodule, releases will also be available as tags. This project's
18-
include folder should then be added to your project's include path. Again, all
19-
functionality is exposed through `#include "cppspec.hpp"`.
20-
21-
If you want to manually generate the collated `cppspec.hpp` yourself, you can download the ccollate tool [here](https://github.com/toroidal-code/ccollate/master/ccollate.rb) and then run `./ccollate.rb include/cppspec.hpp > cppspec.hpp` in the
22-
toplevel directory of the C++Spec repo. A fully-featured `cppspec.hpp` file
23-
will then be available in the root of the project for usage.
11+
See [http://cppspec.readthedocs.org/](http://cppspec.readthedocs.org/) for full documentation and a tutorial.
2412

13+
## Requirements
2514

26-
## Documentation ##
15+
C++Spec requires a compiler and standard library with support for C++20.
2716

28-
See [http://cppspec.readthedocs.org/](http://cppspec.readthedocs.org/) for full documentation and a tutorial.
17+
__Note:__ Only the tests require being compiled with C++20 support (`-std=c++20`). No other part of an existing project's build must be modified.
2918

30-
## Requirements ##
19+
## Usage
20+
The recommended usage is as a subproject integrated into your build system. For CMake this would look something like below:
21+
```cmake
22+
FetchContent_Declare(
23+
c++spec
24+
GIT_REPOSITORY https://github.com/toroidal-code/cppspec
25+
GIT_TAG VERSION
26+
)
3127
32-
C++Spec requires a compiler with support for C++11 and polymorphic lambda expressions from C++14. This includes GCC >= 4.9, MSVCC >= 14.0, or clang >= 3.4. For other compilers check [this chart](http://en.cppreference.com/w/cpp/compiler_support).
33-
34-
__Note:__ Only the tests require being compiled with C++14 support (`-std=c++14`). No other part of an existing project's build must be modified.
28+
# Or using CPM
29+
CPMAddPackage("gh:toroidal-code/cppspec@VERSION")
30+
```
3531

36-
## Introduction ##
32+
## Introduction
3733

3834
If you've ever used RSpec or Jasmine, chances are you'll be familiar with C++Spec's syntax. For example, this is a C++Spec version of the first snippet on RSpec's [README](https://github.com/rspec/rspec-core/blob/master/README.md#basic-structure).
3935

@@ -58,22 +54,16 @@ describe order_spec("Order", $ {
5854
});
5955
});
6056

61-
62-
int main(){
63-
return CppSpec::Runner(CppSpec::Formatters::verbose)
64-
.add_spec(order_spec)
65-
.exec() ? EXIT_SUCCESS : EXIT_FAILURE;
66-
}
67-
57+
CPPSPEC_MAIN(order_spec);
6858
```
6959
70-
## FAQ ##
60+
## FAQ
7161
72-
## Attribution ##
62+
## Attribution
7363
Heavily inspired by [RSpec](https://github.com/rspec) and [Jasmine](http://jasmine.github.io).
7464
75-
## Authors ##
76-
Copyright © 2014-2016 Katherine Whitlock
65+
## Authors
66+
Copyright © 2014-2024 Katherine Whitlock
7767
78-
## License ##
68+
## License
7969
The project is licensed under the MIT License.

0 commit comments

Comments
 (0)