diff options
Diffstat (limited to 'libca-certificates-curl/tests/basics')
-rw-r--r-- | libca-certificates-curl/tests/basics/buildfile | 7 | ||||
-rw-r--r-- | libca-certificates-curl/tests/basics/driver.c | 19 | ||||
-rw-r--r-- | libca-certificates-curl/tests/basics/testscript | 17 |
3 files changed, 43 insertions, 0 deletions
diff --git a/libca-certificates-curl/tests/basics/buildfile b/libca-certificates-curl/tests/basics/buildfile new file mode 100644 index 0000000..3adb0ff --- /dev/null +++ b/libca-certificates-curl/tests/basics/buildfile @@ -0,0 +1,7 @@ +# file : tests/basic/buildfile +# copyright : Copyright (c) 2009-2019 Code Synthesis Tools CC +# license : Mozilla Public License 2.0; see accompanying LICENSE file + +import libs = libca-certificates-curl%lib{ca-certificates-curl} + +exe{driver}: {h c}{**} $libs testscript diff --git a/libca-certificates-curl/tests/basics/driver.c b/libca-certificates-curl/tests/basics/driver.c new file mode 100644 index 0000000..f52b3d8 --- /dev/null +++ b/libca-certificates-curl/tests/basics/driver.c @@ -0,0 +1,19 @@ +/* file : tests/basic/driver.c + * copyright : Copyright (c) 2009-2019 Code Synthesis Tools CC + * license : Mozilla Public License 2.0; see accompanying LICENSE file + */ +#include <stdio.h> + +#include <libca-certificates-curl/path.h> +#include <libca-certificates-curl/version.h> + +/* Usage: argv[0] + * + * Print the CA certificates file path to stdout. + */ +int +main () +{ + printf ("%s\n", ca_certificates_file ()); + return 0; +} diff --git a/libca-certificates-curl/tests/basics/testscript b/libca-certificates-curl/tests/basics/testscript new file mode 100644 index 0000000..ffa60ad --- /dev/null +++ b/libca-certificates-curl/tests/basics/testscript @@ -0,0 +1,17 @@ +# file : tests/basic/testscript +# copyright : Copyright (c) 2016-2019 Code Synthesis Ltd +# license : Mozilla Public License 2.0; see accompanying LICENSE file + +: basic +: +{ + $* | set f; + + cat "$f" >>~%EOO% + %.* + -----BEGIN CERTIFICATE----- + %.+ + -----END CERTIFICATE----- + %* + EOO +} |