Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
Actor Framework
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
cpp-libs
Actor Framework
Commits
3f2d2713
Commit
3f2d2713
authored
Aug 20, 2023
by
Dominik Charousset
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cover expect/allow/inject in the new test readme
parent
4c684ddf
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
1 deletion
+15
-1
libcaf_test/README.md
libcaf_test/README.md
+15
-1
No files found.
libcaf_test/README.md
View file @
3f2d2713
...
...
@@ -337,10 +337,24 @@ To migrate to the new framework:
For users of the old `
caf/test/dsl.hpp
` header:
- Include `
caf/test/scenario.hpp
` instead of `
caf/test/dsl.hpp
`.
- The BDD-style macros still have the same names. However, CAF now runs each
branch of a BDD-style test independently. Hence, old tests with multiple
a
`
WHEN
` blocks might behave slightly differently now.
`
WHEN
` blocks might behave slightly differently now.
- Instead of using the `
test_coordinator_fixture
`, use
`
caf::test::fixture::deterministic
`. The interface is mostly the same, but
there are some differences. Please refer to the class documentation for more
details.
- Macros such as `
expect
`, `
allow
` and `
inject
` have been replaced by member
functions on the new deterministic fixture. Hence, the syntax has changed
slightly:
```
old: expect((int), with(42).from(foo).to(bar))
new: expect<int>().with(42).from(foo).to(bar)
old: allow((int), with(42).from(foo).to(bar))
new: allow<int>().with(42).from(foo).to(bar)
old: inject((int), with(42).from(foo).to(bar))
new: inject().with(42).from(foo).to(bar)
``
`
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment