test-esys.h 1.2 KB

1234567891011121314151617181920212223242526272829303132
  1. /* SPDX-License-Identifier: BSD-2-Clause */
  2. /***********************************************************************
  3. * Copyright 2017-2018, Fraunhofer SIT sponsored by Infineon Technologies AG
  4. * Copyright (c) 2017-2018, Intel Corporation
  5. *
  6. * All rights reserved.
  7. ***********************************************************************/
  8. #include "tss2_esys.h"
  9. #define TSSWG_INTEROP 1
  10. #define TSS_SAPI_FIRST_FAMILY 2
  11. #define TSS_SAPI_FIRST_LEVEL 1
  12. #define TSS_SAPI_FIRST_VERSION 108
  13. #define EXIT_SKIP 77
  14. #define EXIT_XFAIL 99
  15. #define goto_error_if_not_failed(rc,msg,label) \
  16. if (rc == TSS2_RC_SUCCESS) { \
  17. LOG_ERROR("Error %s (%x) in Line %i: \n", msg, __LINE__, rc); \
  18. goto label; }
  19. /*
  20. * This is the prototype for all integration tests in the tpm2-tss
  21. * project. Integration tests are intended to exercise the combined
  22. * components in the software stack. This typically means executing some
  23. * SYS function using the socket TCTI to communicate with a software
  24. * TPM2 simulator.
  25. * Return values:
  26. * A successful test will return 0, any other value indicates failure.
  27. */
  28. int test_invoke_esys(ESYS_CONTEXT * sys_context);