diff --git a/src/tests.h b/src/tests.h index 0280d2cd..e7adfbe3 100644 --- a/src/tests.h +++ b/src/tests.h @@ -6,12 +6,21 @@ ** @{ */ +/** +** Options to control how tests are run. +*/ typedef struct _tf_test_options_t { + /** The path to the Tilde Friends executable, in order to run subprocesses. */ const char* exe_path; + /** A comma-separated list of tests to run, or NULL. */ const char* tests; } tf_test_options_t; +/** +** Run tests. +** @param options Test options. +*/ void tf_tests(const tf_test_options_t* options); /** @} */ diff --git a/src/tlscontext.js.h b/src/tlscontext.js.h index 23e2332d..18ae113d 100644 --- a/src/tlscontext.js.h +++ b/src/tlscontext.js.h @@ -8,10 +8,30 @@ #include "quickjs.h" +/** +** A TLS context instance. +*/ typedef struct _tf_tls_context_t tf_tls_context_t; +/** +** Register TLS script interface. +** @param context The TLS context. +** @return the TlsContext constructor. +*/ JSValue tf_tls_context_register(JSContext* context); + +/** +** Get a TLS context instance from its JS object. +** @param value A TlsContext JS object. +** @return The corresponding instance. +*/ tf_tls_context_t* tf_tls_context_get(JSValue value); + +/** +** Get the number of active TLS context instances. +** @return The number of TlsContext objects created that have not been +** finalized. +*/ int tf_tls_context_get_count(); /** @} */