Richard Levitte 3ea75c6328 For every test in 80-test_ssl.t, check that the protocol(s) used is enabled 8 yıl önce
..
Attic 71a4f2832c Remove old testing scripts out of the way. 8 yıl önce
certs 6e8beabcd4 More X509_verify_cert() tests via verify(1). 8 yıl önce
ocsp-tests 30c278aa6b Fix OCSP checking. 11 yıl önce
recipes 3ea75c6328 For every test in 80-test_ssl.t, check that the protocol(s) used is enabled 8 yıl önce
smime-certs 75787fd833 Add X9.42 DH certificate to S/MIME test 11 yıl önce
testlib 83365051f5 Make tests use configdata.pm rather than parsing Makefile 8 yıl önce
CAss.cnf fec669388c Use 2K RSA and SHA256 in tests 9 yıl önce
CAssdh.cnf 58964a4922 Import of old SSLeay release: SSLeay 0.9.0b 25 yıl önce
CAssdsa.cnf 58964a4922 Import of old SSLeay release: SSLeay 0.9.0b 25 yıl önce
CAssrsa.cnf 58964a4922 Import of old SSLeay release: SSLeay 0.9.0b 25 yıl önce
CAtsa.cnf 2cc7acd273 Use better defaults for TSA. 8 yıl önce
Makefile.in 56c77c52e1 Remove update tags 8 yıl önce
P1ss.cnf fec669388c Use 2K RSA and SHA256 in tests 9 yıl önce
P2ss.cnf fec669388c Use 2K RSA and SHA256 in tests 9 yıl önce
README 5ab4f893ce Add documentation for the new testing framework 8 yıl önce
Sssdsa.cnf 58964a4922 Import of old SSLeay release: SSLeay 0.9.0b 25 yıl önce
Sssrsa.cnf 58964a4922 Import of old SSLeay release: SSLeay 0.9.0b 25 yıl önce
Uss.cnf cb0585c2cb Create DSA and ECDSA certificates. 8 yıl önce
asynctest.c 8d35ceb98f Use POSIX functions on Cygwin, not Win32 function 8 yıl önce
bftest.c 16f8d4ebf0 memset, memcpy, sizeof consistency fixes 9 yıl önce
bntest.c 8ffcca6586 Remove test_probable_prime_coprime from test/bntest.c 8 yıl önce
casttest.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
clean_test.com f0d9196237 * apps/makeapps.com: Forgot to end the check for /POINTER_SIZE=64=ARGV 13 yıl önce
clienthellotest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
cms-examples.pl 4a954b56c9 Use "cont" consistently in cms-examples.pl 16 yıl önce
constant_time_test.c 80e0ecbf58 Add ossl_inline 8 yıl önce
danetest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
danetest.in 170b735820 DANE support for X509_verify_cert() 8 yıl önce
danetest.pem 170b735820 DANE support for X509_verify_cert() 8 yıl önce
destest.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
dhtest.c bbd86bf542 mem functions cleanup 8 yıl önce
dsatest.c 70c9f1c878 dsatest: use the correct BIO to print the test error 8 yıl önce
dummytest.c 7644a9aef8 Rename some BUF_xxx to OPENSSL_xxx 8 yıl önce
ecdhtest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
ecdsatest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
ectest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
enginetest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
evp_extra_test.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
evp_test.c 44a284d292 Add TLS1-PRF test support to evp_test 8 yıl önce
evptests.txt 53a3a545c3 add TLS1-PRF tests 8 yıl önce
exdatatest.c e6390acac9 ex_data part 2: doc fixes and CRYPTO_free_ex_index. 8 yıl önce
exptest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
gmdifftest.c 3a3cb629d9 Check OPENSSL_gmtime_diff 8 yıl önce
heartbeat_test.c 7644a9aef8 Rename some BUF_xxx to OPENSSL_xxx 8 yıl önce
hmactest.c a87a0a6e5e Cleanup: fix all sources that used HMAC_CTX_init 8 yıl önce
ideatest.c df2ee0e27d Enable -Wmissing-variable-declarations and 8 yıl önce
igetest.c 31384753c7 Remove the "eay" c-file-style indicators 8 yıl önce
jpaketest.c cf926b4563 fix jpaketest and correct comment 8 yıl önce
maketests.com cdca82dcde Catch up the VMS build. 9 yıl önce
md2test.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
md4test.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
md5test.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
mdc2test.c bfb0641f93 Cleanup: fix all sources that used EVP_MD_CTX_(create|init|destroy) 8 yıl önce
memleaktest.c ec04e86634 Update leak test to check return values. 8 yıl önce
methtest.c 35a1cc90bc More comment realignment 9 yıl önce
nptest.c d4ab70f27c Test for NULL ptr == 0 8 yıl önce
p5_crpt2_test.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
packettest.c 3101154481 DTLS: remove unused cookie field 8 yıl önce
pbelutest.c d95466931d PBE lookup test 8 yıl önce
pkcs7-1.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
pkcs7.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
pkits-test.pl be16cc23c6 detect and use older PKITS data 12 yıl önce
r160test.c 0f113f3ee4 Run util/openssl-format-source -v -c . 9 yıl önce
randtest.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
rc2test.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
rc4test.c 16f8d4ebf0 memset, memcpy, sizeof consistency fixes 9 yıl önce
rc5test.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
rmdtest.c dee502be89 Stop symlinking, move files to intended directory 9 yıl önce
rsa_test.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
run_tests.pl df7421ccb4 few typo fixes 8 yıl önce
secmemtest.c 74924dcb38 More secure storage of key material. 9 yıl önce
serverinfo.pem c655f40ed2 Require ServerInfo PEMs to be named "BEGIN SERVERINFO FOR"... 10 yıl önce
sha1test.c c376d170d1 Cleanup the EVP_MD_CTX before exit rather than after 8 yıl önce
sha256t.c bfb0641f93 Cleanup: fix all sources that used EVP_MD_CTX_(create|init|destroy) 8 yıl önce
sha512t.c bfb0641f93 Cleanup: fix all sources that used EVP_MD_CTX_(create|init|destroy) 8 yıl önce
smcont.txt 7d7e640e0b Add extensive PCKS7 and CMS consistency test script. 16 yıl önce
srptest.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
ssltest.c 6b01bed206 Support disabling any or all TLS or DTLS versions 8 yıl önce
test.cnf fec669388c Use 2K RSA and SHA256 in tests 9 yıl önce
test_aesni 799379215e test_aesni: harmonize with AES-NI support at EVP layer. 12 yıl önce
test_padlock b066c3cd50 Update test/test_padlock script. 15 yıl önce
test_t4 c5d975a743 Add support for SPARC T4 DES opcode. 11 yıl önce
testcrl.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
testdsa.pem 79a578b902 Add private/public key conversion tests 9 yıl önce
testdsapub.pem 79a578b902 Add private/public key conversion tests 9 yıl önce
testec-p256.pem 79a578b902 Add private/public key conversion tests 9 yıl önce
testecpub-p256.pem 79a578b902 Add private/public key conversion tests 9 yıl önce
testp7.pem dcb1ef5c22 Change PKCS#7 test data to take account of removal of 24 yıl önce
testreq2.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
testrsa.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
testrsapub.pem 79a578b902 Add private/public key conversion tests 9 yıl önce
tests.com cdca82dcde Catch up the VMS build. 9 yıl önce
testsid.pem 45f55f6a5b Remove SSLv2 support 9 yıl önce
testutil.c bdcb1a2cf5 more OSSL_NELEM cases 9 yıl önce
testutil.h 0f113f3ee4 Run util/openssl-format-source -v -c . 9 yıl önce
testx509.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
times 8711efb498 Updates from 1.0.0-stable branch. 15 yıl önce
v3-cert1.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
v3-cert2.pem d02b48c63a Import of old SSLeay release: SSLeay 0.8.1b 25 yıl önce
v3nametest.c 9f9a39267f NGX-2040 - fix wildcard match on punycode/IDNA DNS names 8 yıl önce
verify_extra_test.c c2e27310c7 Enable/disable crypto-mdebug just like other features 8 yıl önce
wp_test.c df2ee0e27d Enable -Wmissing-variable-declarations and 8 yıl önce

README

How to add recipes
==================

For any test that you want to perform, you write a script located in
test/recipes/, named {nn}-test_{name}.t, where {nn} is a two digit number and
{name} is a unique name of your choice.

Please note that if a test involves a new testing executable, you will need to
do some additions in test/Makefile. More on this later.


Naming convetions
=================

A test executable is named test/{name}test.c

A test recipe is named test/recipes/{nn}-test_{name}.t, where {nn} is a two
digit number and {name} is a unique name of your choice.

The number {nn} is (somewhat loosely) grouped as follows:

05 individual symmetric cipher algorithms
10 math (bignum)
15 individual asymmetric cipher algorithms
20 openssl enc
25 certificate forms, generation and verification
30 engine and evp
70 PACKET layer
80 "larger" protocols (CA, CMS, OCSP, SSL, TSA)
90 misc


A recipe that just runs a test executable
=========================================

A script that just runs a program looks like this:

#! /usr/bin/perl

use OpenSSL::Test::Simple;

simple_test("test_{name}", "{name}test", "{name}");

{name} is the unique name you have chosen for your test.

The second argument to `simple_test' is the test executable, and `simple_test'
expects it to be located in test/

For documentation on OpenSSL::Test::Simple, do
`perldoc test/testlib/OpenSSL/Test/Simple.pm'.


A recipe that runs a more complex test
======================================

For more complex tests, you will need to read up on Test::More and
OpenSSL::Test. Test::More is normally preinstalled, do `man Test::More' for
documentation. For OpenSSL::Test, do `perldoc test/testlib/OpenSSL/Test.pm'.

A script to start from could be this:

#! /usr/bin/perl

use strict;
use warnings;
use OpenSSL::Test;

setup("test_{name}");

plan tests => 2; # The number of tests being performed

ok(test1, "test1");
ok(test2, "test1");

sub test1
{
# test feature 1
}

sub test2
{
# test feature 2
}


Changes to test/Makefile
========================

Whenever a new test involves a new test executable you need to do the
following (at all times, replace {NAME} and {name} with the name of your
test):

* among the variables for test executables at the beginning, add a line like
this:

{NAME}TEST= {name}test

* add `$({NAME}TEST)$(EXE_EXT)' to the assignment of EXE:

* add `$({NAME}TEST).o' to the assignment of OBJ:

* add `$({NAME}TEST).c' to the assignment of SRC:

* add the following lines for building the executable:

$({NAME}TEST)$(EXE_EXT): $({NAME}TEST).o $(DLIBCRYPTO)
@target=$({NAME}TEST); $(BUILD_CMD)