File tree Expand file tree Collapse file tree 9 files changed +15
-19
lines changed Expand file tree Collapse file tree 9 files changed +15
-19
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ target_link_libraries(c++spec INTERFACE
35
35
cxx-prettyprint
36
36
argparse
37
37
)
38
- target_compile_options (c++spec INTERFACE -Wno-missing-template-arg-list-after-template-kw )
38
+ target_compile_options (c++spec INTERFACE -Wno-missing-template-arg-list-after-template-kw -Wno-dollar-in-identifier-extension )
39
39
40
40
FILE (GLOB_RECURSE c++spec_headers ${CMAKE_CURRENT_LIST_DIR} /include/*.hpp )
41
41
@@ -79,7 +79,7 @@ if(CPPSPEC_BUILD_TESTS)
79
79
enable_testing ()
80
80
81
81
# Tests
82
- discover_specs (spec )
82
+ add_subdirectory (spec )
83
83
endif (CPPSPEC_BUILD_TESTS )
84
84
85
85
if (CPPSPEC_BUILD_EXAMPLES )
Original file line number Diff line number Diff line change
1
+ add_compile_options (-Wall -Wextra -Wpedantic )
2
+
1
3
add_subdirectory (sample )
2
4
#add_subdirectory(skip)
3
- #add_subdirectory(xml_output)
5
+ #add_subdirectory(xml_output)
Original file line number Diff line number Diff line change @@ -7,6 +7,7 @@ target_link_libraries(cppspec_sample c++spec)
7
7
add_executable (jasmine_intro jasmine_intro.cpp )
8
8
target_link_libraries (jasmine_intro c++spec )
9
9
10
+
10
11
set_target_properties (cppspec_sample jasmine_intro PROPERTIES
11
12
CXX_STANDARD 23
12
13
CXX_STANDARD_REQUIRED YES
Original file line number Diff line number Diff line change @@ -71,8 +71,8 @@ class Child {
71
71
/* --------- Parent helper functions -------------*/
72
72
73
73
/* * @brief Check to see if the Child has a parent. */
74
- const bool has_parent () noexcept { return parent != nullptr ; }
75
- [[nodiscard]] const bool has_parent () const noexcept { return parent != nullptr ; }
74
+ bool has_parent () noexcept { return parent != nullptr ; }
75
+ [[nodiscard]] bool has_parent () const noexcept { return parent != nullptr ; }
76
76
77
77
// TODO: Look in to making these references instead of pointer returns
78
78
/* * @brief Get the Child's parent. */
Original file line number Diff line number Diff line change 19
19
#define specify it
20
20
21
21
// Apparently MSVC++ doesn't conform to C++14 14.2/4. Annoying.
22
- #if defined(_MSC_VER) && !defined(__clang__)
23
22
#define context self.context
24
23
#define expect self.expect
25
- #else
26
- #define context self.template context
27
- #define expect self.template expect
28
- #endif
29
24
#define explain context // Piggybacks off of the `context` macro
30
25
31
26
#define is_expected self.is_expected
Original file line number Diff line number Diff line change @@ -55,8 +55,6 @@ class Expectation : public Child {
55
55
bool ignore_failure_ = false ;
56
56
57
57
public:
58
- Expectation (const Expectation &) = default ;
59
-
60
58
/* *
61
59
* @brief Create an Expectation using a value.
62
60
*
@@ -399,8 +397,6 @@ class ExpectationValue : public Expectation<A> {
399
397
A value;
400
398
401
399
public:
402
- ExpectationValue (ExpectationValue const ©) : Expectation<A>(copy), value(copy.value) {}
403
-
404
400
/* *
405
401
* @brief Create an ExpectationValue using a value.
406
402
*
Original file line number Diff line number Diff line change @@ -45,10 +45,10 @@ class BaseFormatter {
45
45
46
46
virtual ~BaseFormatter () = default ;
47
47
48
- virtual void format (const Description &description) {}
49
- virtual void format (const ItBase &it ) {}
48
+ virtual void format (const Description & /* description */ ) {}
49
+ virtual void format (const ItBase & /* it */ ) {}
50
50
virtual void format (const std::string &message) { out_stream << message << std::endl; }
51
- virtual void format_failure (const std::string &message) {}
51
+ virtual void format_failure (const std::string & /* message */ ) {}
52
52
virtual void flush () {}
53
53
virtual void cleanup () {}
54
54
Original file line number Diff line number Diff line change @@ -129,12 +129,12 @@ inline std::string Pretty::to_word<bool>(bool &item) {
129
129
}
130
130
131
131
template <>
132
- inline std::string Pretty::to_word<std::true_type>(std::true_type &item) {
132
+ inline std::string Pretty::to_word<std::true_type>(std::true_type & /* item */ ) {
133
133
return " true" ;
134
134
}
135
135
136
136
template <>
137
- inline std::string Pretty::to_word<std::false_type>(std::false_type &item) {
137
+ inline std::string Pretty::to_word<std::false_type>(std::false_type & /* item */ ) {
138
138
return " false" ;
139
139
}
140
140
Original file line number Diff line number Diff line change
1
+ add_compile_options (-Wno-unused-parameter -Wno-missing-template-arg-list-after-template-kw )
2
+ discover_specs (${CMAKE_CURRENT_SOURCE_DIR} )
You can’t perform that action at this time.
0 commit comments