mirror of
https://github.com/arun11299/cpp-jwt.git
synced 2025-05-15 01:08:31 +00:00
Fixed many warnings that appear due to assert not being executed in
release mode.
This commit is contained in:
parent
9ff6e50b5e
commit
00343347b2
4 changed files with 13 additions and 9 deletions
|
@ -37,12 +37,10 @@ int main() {
|
|||
|
||||
//Using `add_claim` with extra features.
|
||||
//Check return status and overwrite
|
||||
bool ret = obj.payload().add_claim("sub", "new test", false/*overwrite*/);
|
||||
assert (not ret);
|
||||
assert (not obj.payload().add_claim("sub", "new test", false/*overwrite*/));
|
||||
|
||||
// Overwrite an existing claim
|
||||
ret = obj.payload().add_claim("sub", "new test", true/*overwrite*/);
|
||||
assert ( ret );
|
||||
assert (obj.payload().add_claim("sub", "new test", true/*overwrite*/));
|
||||
|
||||
assert (obj.payload().has_claim_with_value("sub", "new test"));
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue