/freebsd/crypto/openssl/test/ |
H A D | cmp_protect_test.c | 38 static void tear_down(CMP_PROTECT_TEST_FIXTURE *fixture) in tear_down() argument 40 if (fixture != NULL) { in tear_down() 41 OSSL_CMP_CTX_free(fixture->cmp_ctx); in tear_down() 42 OSSL_CMP_MSG_free(fixture->msg); in tear_down() 43 OSSL_CMP_PKISI_free(fixture->si); in tear_down() 45 OPENSSL_free(fixture->mem); in tear_down() 46 sk_X509_free(fixture->certs); in tear_down() 47 sk_X509_free(fixture->chain); in tear_down() 49 OPENSSL_free(fixture); in tear_down() 55 CMP_PROTECT_TEST_FIXTURE *fixture; in set_up() local [all …]
|
H A D | cmp_msg_test.c | 38 static void tear_down(CMP_MSG_TEST_FIXTURE *fixture) in tear_down() argument 40 OSSL_CMP_CTX_free(fixture->cmp_ctx); in tear_down() 41 OSSL_CMP_MSG_free(fixture->msg); in tear_down() 42 OSSL_CMP_PKISI_free(fixture->si); in tear_down() 43 OPENSSL_free(fixture); in tear_down() 50 CMP_MSG_TEST_FIXTURE *fixture; in set_up() local 52 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 54 fixture->test_case_name = test_case_name; in set_up() 56 if (!TEST_ptr(fixture->cmp_ctx = OSSL_CMP_CTX_new(libctx, NULL)) in set_up() 57 || !TEST_true(SET_OPT_UNPROTECTED_SEND(fixture->cmp_ctx, 1)) in set_up() [all …]
|
H A D | cmp_vfy_test.c | 43 static void tear_down(CMP_VFY_TEST_FIXTURE *fixture) in tear_down() argument 45 OSSL_CMP_MSG_free(fixture->msg); in tear_down() 46 OSSL_CMP_CTX_free(fixture->cmp_ctx); in tear_down() 47 OPENSSL_free(fixture); in tear_down() 55 CMP_VFY_TEST_FIXTURE *fixture; in set_up() local 57 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 61 fixture->test_case_name = test_case_name; in set_up() 63 || !TEST_ptr(fixture->cmp_ctx = OSSL_CMP_CTX_new(libctx, NULL)) in set_up() 64 || !OSSL_CMP_CTX_set0_trustedStore(fixture->cmp_ctx, ts) in set_up() 65 || !OSSL_CMP_CTX_set_log_cb(fixture->cmp_ctx, print_to_bio_out)) { in set_up() [all …]
|
H A D | ct_test.c | 62 CT_TEST_FIXTURE *fixture = NULL; in set_up() local 64 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 66 fixture->test_case_name = test_case_name; in set_up() 67 fixture->epoch_time_in_ms = 1580335307000ULL; /* Wed 29 Jan 2020 10:01:47 PM UTC */ in set_up() 68 if (!TEST_ptr(fixture->ctlog_store = CTLOG_STORE_new()) in set_up() 70 CTLOG_STORE_load_default_file(fixture->ctlog_store), 1)) in set_up() 72 return fixture; in set_up() 75 if (fixture != NULL) in set_up() 76 CTLOG_STORE_free(fixture in set_up() 82 tear_down(CT_TEST_FIXTURE * fixture) tear_down() argument 183 assert_validity(CT_TEST_FIXTURE * fixture,STACK_OF (SCT)* scts,CT_POLICY_EVAL_CTX * policy_ctx) assert_validity() argument 224 execute_cert_test(CT_TEST_FIXTURE * fixture) execute_cert_test() argument [all...] |
H A D | cmp_hdr_test.c | 24 static void tear_down(CMP_HDR_TEST_FIXTURE *fixture) in tear_down() argument 26 OSSL_CMP_PKIHEADER_free(fixture->hdr); in tear_down() 27 OSSL_CMP_CTX_free(fixture->cmp_ctx); in tear_down() 28 OPENSSL_free(fixture); in tear_down() 33 CMP_HDR_TEST_FIXTURE *fixture; in set_up() local 35 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 37 fixture->test_case_name = test_case_name; in set_up() 38 if (!TEST_ptr(fixture->cmp_ctx = OSSL_CMP_CTX_new(NULL, NULL))) in set_up() 40 if (!TEST_ptr(fixture in set_up() 49 execute_HDR_set_get_pvno_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_set_get_pvno_test() argument 72 execute_HDR_get0_senderNonce_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_get0_senderNonce_test() argument 103 execute_HDR_set1_sender_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_set1_sender_test() argument 132 execute_HDR_set1_recipient_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_set1_recipient_test() argument 162 execute_HDR_update_messageTime_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_update_messageTime_test() argument 200 execute_HDR_set1_senderKID_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_set1_senderKID_test() argument 230 execute_HDR_push0_freeText_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_push0_freeText_test() argument 261 execute_HDR_push1_freeText_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_push1_freeText_test() argument 295 execute_HDR_generalInfo_push0_item_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_generalInfo_push0_item_test() argument 322 execute_HDR_generalInfo_push1_items_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_generalInfo_push1_items_test() argument 382 execute_HDR_set_and_check_implicitConfirm_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_set_and_check_implicitConfirm_test() argument 397 execute_HDR_init_test(CMP_HDR_TEST_FIXTURE * fixture) execute_HDR_init_test() argument [all...] |
H A D | cmp_client_test.c | 48 static void tear_down(CMP_SES_TEST_FIXTURE *fixture) in tear_down() argument 50 OSSL_CMP_CTX_free(fixture->cmp_ctx); in tear_down() 51 ossl_cmp_mock_srv_free(fixture->srv_ctx); in tear_down() 52 sk_X509_free(fixture->caPubs); in tear_down() 53 OPENSSL_free(fixture); in tear_down() 58 CMP_SES_TEST_FIXTURE *fixture; in set_up() local 62 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 64 fixture->test_case_name = test_case_name; in set_up() 65 if (!TEST_ptr(fixture->srv_ctx = ossl_cmp_mock_srv_new(libctx, NULL)) in set_up() 66 || !OSSL_CMP_SRV_CTX_set_accept_unprotected(fixture->srv_ctx, 1) in set_up() [all …]
|
H A D | cmp_asn_test.c | 26 CMP_ASN_TEST_FIXTURE *fixture; in set_up() local 28 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 30 fixture->test_case_name = test_case_name; in set_up() 31 return fixture; in set_up() 34 static void tear_down(CMP_ASN_TEST_FIXTURE *fixture) in tear_down() argument 36 ASN1_OCTET_STRING_free(fixture->src_string); in tear_down() 37 if (fixture->tgt_string != fixture->src_string) in tear_down() 38 ASN1_OCTET_STRING_free(fixture->tgt_string); in tear_down() 40 OPENSSL_free(fixture); in tear_down() 43 static int execute_cmp_asn1_get_int_test(CMP_ASN_TEST_FIXTURE *fixture) in execute_cmp_asn1_get_int_test() argument [all …]
|
H A D | ssl_test_ctx_test.c | 112 SSL_TEST_CTX_TEST_FIXTURE *fixture; in set_up() local 114 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 116 fixture->test_case_name = test_case_name; in set_up() 117 if (!TEST_ptr(fixture->expected_ctx = SSL_TEST_CTX_new(NULL))) { in set_up() 118 OPENSSL_free(fixture); in set_up() 121 return fixture; in set_up() 124 static int execute_test(SSL_TEST_CTX_TEST_FIXTURE *fixture) in execute_test() argument 129 if (!TEST_ptr(ctx = SSL_TEST_CTX_create(conf, fixture->test_section, in execute_test() 130 fixture->expected_ctx->libctx)) in execute_test() 131 || !testctx_eq(ctx, fixture->expected_ctx)) in execute_test() [all …]
|
H A D | cmp_status_test.c | 24 CMP_STATUS_TEST_FIXTURE *fixture; in set_up() local 26 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 28 fixture->test_case_name = test_case_name; in set_up() 29 return fixture; in set_up() 32 static void tear_down(CMP_STATUS_TEST_FIXTURE *fixture) in tear_down() argument 34 OPENSSL_free(fixture); in tear_down() 41 static int execute_PKISI_test(CMP_STATUS_TEST_FIXTURE *fixture) in execute_PKISI_test() argument 48 if (!TEST_ptr(si = OSSL_CMP_STATUSINFO_new(fixture->pkistatus, in execute_PKISI_test() 49 fixture->pkifailure, in execute_PKISI_test() 50 fixture->text))) in execute_PKISI_test() [all …]
|
H A D | cipherlist_test.c | 31 static void tear_down(CIPHERLIST_TEST_FIXTURE *fixture) in tear_down() argument 33 if (fixture != NULL) { in tear_down() 34 SSL_CTX_free(fixture->server); in tear_down() 35 SSL_CTX_free(fixture->client); in tear_down() 36 fixture->server = fixture->client = NULL; in tear_down() 37 OPENSSL_free(fixture); in tear_down() 43 CIPHERLIST_TEST_FIXTURE *fixture; in set_up() local 45 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 47 fixture->test_case_name = test_case_name; in set_up() 48 if (!TEST_ptr(fixture->server = SSL_CTX_new(TLS_server_method())) in set_up() [all …]
|
H A D | cmp_server_test.c | 25 static void tear_down(CMP_SRV_TEST_FIXTURE *fixture) in tear_down() argument 27 OSSL_CMP_SRV_CTX_free(fixture->srv_ctx); in tear_down() 28 OPENSSL_free(fixture); in tear_down() 33 CMP_SRV_TEST_FIXTURE *fixture; in set_up() local 35 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 37 fixture->test_case_name = test_case_name; in set_up() 38 if (!TEST_ptr(fixture->srv_ctx = OSSL_CMP_SRV_CTX_new(libctx, NULL))) in set_up() 40 return fixture; in set_up() 43 tear_down(fixture); in set_up() 62 static int execute_test_handle_request(CMP_SRV_TEST_FIXTURE *fixture) in execute_test_handle_request() argument [all …]
|
H A D | keymgmt_internal_test.c | 40 static void tear_down(FIXTURE *fixture) in tear_down() argument 42 if (fixture != NULL) { in tear_down() 43 OSSL_PROVIDER_unload(fixture->prov1); in tear_down() 44 OSSL_PROVIDER_unload(fixture->prov2); in tear_down() 45 OSSL_LIB_CTX_free(fixture->ctx1); in tear_down() 46 OSSL_LIB_CTX_free(fixture->ctx2); in tear_down() 47 OPENSSL_free(fixture); in tear_down() 53 FIXTURE *fixture; in set_up() local 55 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture))) in set_up() 142 test_pass_rsa(FIXTURE * fixture) test_pass_rsa() argument [all...] |
H A D | cmp_ctx_test.c | 26 static void tear_down(OSSL_CMP_CTX_TEST_FIXTURE *fixture) in tear_down() argument 28 if (fixture != NULL) in tear_down() 29 OSSL_CMP_CTX_free(fixture->ctx); in tear_down() 30 OPENSSL_free(fixture); in tear_down() 35 OSSL_CMP_CTX_TEST_FIXTURE *fixture; in set_up() local 37 if (!TEST_ptr(fixture = OPENSSL_zalloc(sizeof(*fixture)))) in set_up() 39 if (!TEST_ptr(fixture->ctx = OSSL_CMP_CTX_new(NULL, NULL))) { in set_up() 40 tear_down(fixture); in set_up() 43 fixture->test_case_name = test_case_name; in set_up() 44 return fixture; in set_up() [all …]
|
H A D | modes_internal_test.c | 183 static int execute_cts128(const CTS128_FIXTURE *fixture, int num) in execute_cts128() argument 197 TEST_info("%s_vector_%lu", fixture->case_name, (unsigned long)len); in execute_cts128() 199 tail = fixture->last_blocks_correction(orig_vector, vector, len); in execute_cts128() 203 if (!TEST_size_t_eq(fixture->encrypt_block(test_input, ciphertext, len, in execute_cts128() 212 size = fixture->decrypt_block(ciphertext, cleartext, len, in execute_cts128() 222 if (!TEST_size_t_eq(fixture->encrypt_stream(test_input, ciphertext, len, in execute_cts128() 232 if (!TEST_size_t_eq(fixture->decrypt_stream(ciphertext, cleartext, len, in execute_cts128()
|
H A D | testutil.h | 99 TEST_FIXTURE_TYPE *fixture = set_up(TEST_CASE_NAME); \ 102 if (fixture == NULL) \ 107 if (fixture != NULL) {\ 108 result = execute_func(fixture);\ 109 tear_down(fixture);\
|
/freebsd/contrib/googletest/docs/ |
H A D | primer.md | 92 *test fixture* class. 208 can use a *test fixture*. This allows you to reuse the same configuration of 211 To create a fixture: 214 we'll want to access fixture members from sub-classes. 226 When using a fixture, use `TEST_F()` instead of `TEST()` as it allows you to 227 access objects and subroutines in the test fixture: 236 fixture class. (`_F` stands for "Fixture"). No test suite name is specified for 243 Also, you must first define a test fixture class before using it in a 248 fixture at runtime, immediately initialize it via `SetUp()`, run the test, clean 249 up by calling `TearDown()`, and then delete the test fixture. Note that [all …]
|
H A D | faq.md | 197 ## Can I derive a test fixture from another? 201 Each test fixture has a corresponding and same named test suite. This means only 202 one test suite can use a particular fixture. Sometimes, however, multiple test 207 In GoogleTest, you share a fixture among test suites by putting the shared logic 208 in a base test fixture, then deriving from that base a separate fixture for each 210 tests using each derived fixture. 215 // Defines a base test fixture. 221 // Derives a fixture FooTest from BaseTest. 225 BaseTest::SetUp(); // Sets up the base fixture first. 231 BaseTest::TearDown(); // Remember to tear down the base fixture [all …]
|
H A D | samples.md | 11 * Sample #3 uses a test fixture. 14 * Sample #5 puts shared testing logic in a base test fixture, and reuses it in
|
H A D | advanced.md | 241 a method of the test fixture class. The one constraint is that assertions that 295 GTEST_SKIP() << "Skipping all tests for this fixture"; 488 If a test fixture class is shared by normal tests and death tests, you can use 489 `using` or `typedef` to introduce an alias for the fixture class and avoid 838 fixture, you must add the `::testing::Test::` prefix, as in: 876 > `TEST` body and the test fixture class. 889 GoogleTest creates a new test fixture object for each test in order to make 898 1. In your test fixture class (say `FooTest` ), declare as `static` some member 900 2. Outside your test fixture class (typically just below it), define those 902 3. In the same test fixture class, define a public member function `static void [all …]
|
H A D | gmock_faq.md | 232 fixture's set-up phase) and customize it with more specific rules later. If
|
/freebsd/contrib/googletest/docs/reference/ |
H A D | testing.md | 39 Defines an individual test named *`TestName`* that uses the test fixture class 44 the name of a test fixture class—see 60 test fixture class *`TestFixtureName`*. The test suite name is 65 the name of a value-parameterized test fixture class—see 145 Defines a typed test suite based on the test fixture *`TestFixtureName`*. The 148 The argument *`TestFixtureName`* is a fixture class template, parameterized by a 205 and `TestFixture` refers to the fixture class. See the following example: 214 // To visit static members of the fixture, add the 'TestFixture::' 218 // To refer to typedefs in the fixture, add the 'typename TestFixture::' 233 Defines a type-parameterized test suite based on the test fixture [all …]
|
/freebsd/contrib/googletest/googletest/test/ |
H A D | googletest-output-test-golden-lin.txt | 298 Expected failure #1, in the test fixture c'tor. 318 Expected failure #5, in the test fixture d'tor. 327 Expected failure #1, in the test fixture c'tor. 332 Expected failure #2, in the test fixture d'tor. 356 Expected failure #4, in the test fixture d'tor. 375 Expected failure #3, in the test fixture d'tor. 403 All tests in the same test suite must use the same test fixture 406 using two different test fixture classes. This can happen if 416 All tests in the same test suite must use the same test fixture 419 using two different test fixture classes. This can happen if [all …]
|
/freebsd/crypto/openssl/util/ |
H A D | check-format-test-negatives.c | 424 TEST_FIXTURE *fixture) \ 426 CTX *ctx = fixture->ctx; \
|
/freebsd/tests/ |
H A D | conftest.py | 53 @pytest.fixture(autouse=True, scope="session")
|
/freebsd/contrib/llvm-project/llvm/lib/Target/M68k/ |
H A D | M68kInstrInfo.td | 573 // vt: Type of data this fixture refers to
|