|
1 | | -// Copyright (c) 2023. NetFoundry Inc. |
| 1 | +// Copyright (c) 2023-2026. NetFoundry Inc |
2 | 2 | // |
3 | | -// Licensed under the Apache License, Version 2.0 (the "License"); |
4 | | -// you may not use this file except in compliance with the License. |
5 | | -// You may obtain a copy of the License at |
| 3 | +// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +// you may not use this file except in compliance with the License. |
| 5 | +// You may obtain a copy of the License at |
6 | 6 | // |
7 | | -// https://www.apache.org/licenses/LICENSE-2.0 |
| 7 | +// https://www.apache.org/licenses/LICENSE-2.0 |
8 | 8 | // |
9 | | -// Unless required by applicable law or agreed to in writing, software |
10 | | -// distributed under the License is distributed on an "AS IS" BASIS, |
11 | | -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
12 | | -// See the License for the specific language governing permissions and |
13 | | -// limitations under the License. |
| 9 | +// Unless required by applicable law or agreed to in writing, software |
| 10 | +// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +// See the License for the specific language governing permissions and |
| 13 | +// limitations under the License. |
14 | 14 |
|
15 | 15 | #include "catch2/catch_test_macros.hpp" |
16 | 16 | #include "catch2/matchers/catch_matchers_string.hpp" |
@@ -95,10 +95,11 @@ TEST_CASE("zt_jwt_parse","[model]") { |
95 | 95 | } |
96 | 96 |
|
97 | 97 | TEST_CASE("jwt cred", "[model]") { |
98 | | - ziti_credential_t *cred; |
| 98 | + ziti_log_init(uv_default_loop(), TRACE, NULL); |
| 99 | + ziti_credential_t *cred = nullptr; |
99 | 100 | int rc = ziti_credential_from_jwt(jwt, &cred); |
100 | 101 | CHECK(rc == 0); |
101 | | - CHECK(cred != nullptr); |
| 102 | + REQUIRE(cred != nullptr); |
102 | 103 | CHECK(cred->type == ZITI_CRED_TYPE_JWT); |
103 | 104 | CHECK(cstr_equals(&cred->jwt.issuer, "https://fd200fd3-a2d9-457f-bc0b-f9b8ee7d2898.production.netfoundry.io:443")); |
104 | 105 | ziti_credential_drop(cred); |
|
0 commit comments