🛠️🐜 Antkeeper superbuild with dependencies included https://antkeeper.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

607 lines
18 KiB

  1. /**
  2. * Original code: automated SDL platform test written by Edgar Simo "bobbens"
  3. * Extended and updated by aschiffler at ferzkopp dot net
  4. */
  5. #include <stdio.h>
  6. #include "SDL.h"
  7. #include "SDL_test.h"
  8. /* ================= Test Case Implementation ================== */
  9. /* Helper functions */
  10. /**
  11. * @brief Compare sizes of types.
  12. *
  13. * @note Watcom C flags these as Warning 201: "Unreachable code" if you just
  14. * compare them directly, so we push it through a function to keep the
  15. * compiler quiet. --ryan.
  16. */
  17. static int _compareSizeOfType( size_t sizeoftype, size_t hardcodetype )
  18. {
  19. return sizeoftype != hardcodetype;
  20. }
  21. /* Test case functions */
  22. /**
  23. * @brief Tests type sizes.
  24. */
  25. int platform_testTypes(void *arg)
  26. {
  27. int ret;
  28. ret = _compareSizeOfType( sizeof(Uint8), 1 );
  29. SDLTest_AssertCheck( ret == 0, "sizeof(Uint8) = %lu, expected 1", (unsigned long)sizeof(Uint8) );
  30. ret = _compareSizeOfType( sizeof(Uint16), 2 );
  31. SDLTest_AssertCheck( ret == 0, "sizeof(Uint16) = %lu, expected 2", (unsigned long)sizeof(Uint16) );
  32. ret = _compareSizeOfType( sizeof(Uint32), 4 );
  33. SDLTest_AssertCheck( ret == 0, "sizeof(Uint32) = %lu, expected 4", (unsigned long)sizeof(Uint32) );
  34. ret = _compareSizeOfType( sizeof(Uint64), 8 );
  35. SDLTest_AssertCheck( ret == 0, "sizeof(Uint64) = %lu, expected 8", (unsigned long)sizeof(Uint64) );
  36. return TEST_COMPLETED;
  37. }
  38. /**
  39. * @brief Tests platform endianness and SDL_SwapXY functions.
  40. */
  41. int platform_testEndianessAndSwap(void *arg)
  42. {
  43. int real_byteorder;
  44. int real_floatwordorder = 0;
  45. Uint16 value = 0x1234;
  46. Uint16 value16 = 0xCDAB;
  47. Uint16 swapped16 = 0xABCD;
  48. Uint32 value32 = 0xEFBEADDE;
  49. Uint32 swapped32 = 0xDEADBEEF;
  50. union {
  51. double d;
  52. Uint32 ui32[2];
  53. } value_double;
  54. Uint64 value64, swapped64;
  55. value64 = 0xEFBEADDE;
  56. value64 <<= 32;
  57. value64 |= 0xCDAB3412;
  58. swapped64 = 0x1234ABCD;
  59. swapped64 <<= 32;
  60. swapped64 |= 0xDEADBEEF;
  61. value_double.d = 3.141593;
  62. if ((*((char *) &value) >> 4) == 0x1) {
  63. real_byteorder = SDL_BIG_ENDIAN;
  64. } else {
  65. real_byteorder = SDL_LIL_ENDIAN;
  66. }
  67. /* Test endianness. */
  68. SDLTest_AssertCheck( real_byteorder == SDL_BYTEORDER,
  69. "Machine detected as %s endian, appears to be %s endian.",
  70. (SDL_BYTEORDER == SDL_LIL_ENDIAN) ? "little" : "big",
  71. (real_byteorder == SDL_LIL_ENDIAN) ? "little" : "big" );
  72. if (value_double.ui32[0] == 0x82c2bd7f && value_double.ui32[1] == 0x400921fb) {
  73. real_floatwordorder = SDL_LIL_ENDIAN;
  74. } else if (value_double.ui32[0] == 0x400921fb && value_double.ui32[1] == 0x82c2bd7f) {
  75. real_floatwordorder = SDL_BIG_ENDIAN;
  76. }
  77. /* Test endianness. */
  78. SDLTest_AssertCheck( real_floatwordorder == SDL_FLOATWORDORDER,
  79. "Machine detected as having %s endian float word order, appears to be %s endian.",
  80. (SDL_FLOATWORDORDER == SDL_LIL_ENDIAN) ? "little" : "big",
  81. (real_floatwordorder == SDL_LIL_ENDIAN) ? "little" : (real_floatwordorder == SDL_BIG_ENDIAN) ? "big" : "unknown" );
  82. /* Test 16 swap. */
  83. SDLTest_AssertCheck( SDL_Swap16(value16) == swapped16,
  84. "SDL_Swap16(): 16 bit swapped: 0x%X => 0x%X",
  85. value16, SDL_Swap16(value16) );
  86. /* Test 32 swap. */
  87. SDLTest_AssertCheck( SDL_Swap32(value32) == swapped32,
  88. "SDL_Swap32(): 32 bit swapped: 0x%" SDL_PRIX32 " => 0x%" SDL_PRIX32,
  89. value32, SDL_Swap32(value32) );
  90. /* Test 64 swap. */
  91. SDLTest_AssertCheck( SDL_Swap64(value64) == swapped64,
  92. "SDL_Swap64(): 64 bit swapped: 0x%"SDL_PRIX64" => 0x%"SDL_PRIX64,
  93. value64, SDL_Swap64(value64) );
  94. return TEST_COMPLETED;
  95. }
  96. /* !
  97. * \brief Tests SDL_GetXYZ() functions
  98. * \sa
  99. * http://wiki.libsdl.org/SDL_GetPlatform
  100. * http://wiki.libsdl.org/SDL_GetCPUCount
  101. * http://wiki.libsdl.org/SDL_GetCPUCacheLineSize
  102. * http://wiki.libsdl.org/SDL_GetRevision
  103. * http://wiki.libsdl.org/SDL_GetRevisionNumber
  104. */
  105. int platform_testGetFunctions (void *arg)
  106. {
  107. char *platform;
  108. char *revision;
  109. int ret;
  110. size_t len;
  111. platform = (char *)SDL_GetPlatform();
  112. SDLTest_AssertPass("SDL_GetPlatform()");
  113. SDLTest_AssertCheck(platform != NULL, "SDL_GetPlatform() != NULL");
  114. if (platform != NULL) {
  115. len = SDL_strlen(platform);
  116. SDLTest_AssertCheck(len > 0,
  117. "SDL_GetPlatform(): expected non-empty platform, was platform: '%s', len: %i",
  118. platform,
  119. (int) len);
  120. }
  121. ret = SDL_GetCPUCount();
  122. SDLTest_AssertPass("SDL_GetCPUCount()");
  123. SDLTest_AssertCheck(ret > 0,
  124. "SDL_GetCPUCount(): expected count > 0, was: %i",
  125. ret);
  126. ret = SDL_GetCPUCacheLineSize();
  127. SDLTest_AssertPass("SDL_GetCPUCacheLineSize()");
  128. SDLTest_AssertCheck(ret >= 0,
  129. "SDL_GetCPUCacheLineSize(): expected size >= 0, was: %i",
  130. ret);
  131. revision = (char *)SDL_GetRevision();
  132. SDLTest_AssertPass("SDL_GetRevision()");
  133. SDLTest_AssertCheck(revision != NULL, "SDL_GetRevision() != NULL");
  134. return TEST_COMPLETED;
  135. }
  136. /* !
  137. * \brief Tests SDL_HasXYZ() functions
  138. * \sa
  139. * http://wiki.libsdl.org/SDL_Has3DNow
  140. * http://wiki.libsdl.org/SDL_HasAltiVec
  141. * http://wiki.libsdl.org/SDL_HasMMX
  142. * http://wiki.libsdl.org/SDL_HasRDTSC
  143. * http://wiki.libsdl.org/SDL_HasSSE
  144. * http://wiki.libsdl.org/SDL_HasSSE2
  145. * http://wiki.libsdl.org/SDL_HasSSE3
  146. * http://wiki.libsdl.org/SDL_HasSSE41
  147. * http://wiki.libsdl.org/SDL_HasSSE42
  148. * http://wiki.libsdl.org/SDL_HasAVX
  149. */
  150. int platform_testHasFunctions (void *arg)
  151. {
  152. /* TODO: independently determine and compare values as well */
  153. SDL_HasRDTSC();
  154. SDLTest_AssertPass("SDL_HasRDTSC()");
  155. SDL_HasAltiVec();
  156. SDLTest_AssertPass("SDL_HasAltiVec()");
  157. SDL_HasMMX();
  158. SDLTest_AssertPass("SDL_HasMMX()");
  159. SDL_Has3DNow();
  160. SDLTest_AssertPass("SDL_Has3DNow()");
  161. SDL_HasSSE();
  162. SDLTest_AssertPass("SDL_HasSSE()");
  163. SDL_HasSSE2();
  164. SDLTest_AssertPass("SDL_HasSSE2()");
  165. SDL_HasSSE3();
  166. SDLTest_AssertPass("SDL_HasSSE3()");
  167. SDL_HasSSE41();
  168. SDLTest_AssertPass("SDL_HasSSE41()");
  169. SDL_HasSSE42();
  170. SDLTest_AssertPass("SDL_HasSSE42()");
  171. SDL_HasAVX();
  172. SDLTest_AssertPass("SDL_HasAVX()");
  173. return TEST_COMPLETED;
  174. }
  175. /* !
  176. * \brief Tests SDL_GetVersion
  177. * \sa
  178. * http://wiki.libsdl.org/SDL_GetVersion
  179. */
  180. int platform_testGetVersion(void *arg)
  181. {
  182. SDL_version linked;
  183. int major = SDL_MAJOR_VERSION;
  184. int minor = SDL_MINOR_VERSION;
  185. SDL_GetVersion(&linked);
  186. SDLTest_AssertCheck( linked.major >= major,
  187. "SDL_GetVersion(): returned major %i (>= %i)",
  188. linked.major,
  189. major);
  190. SDLTest_AssertCheck( linked.minor >= minor,
  191. "SDL_GetVersion(): returned minor %i (>= %i)",
  192. linked.minor,
  193. minor);
  194. return TEST_COMPLETED;
  195. }
  196. /* !
  197. * \brief Tests SDL_VERSION macro
  198. */
  199. int platform_testSDLVersion(void *arg)
  200. {
  201. SDL_version compiled;
  202. int major = SDL_MAJOR_VERSION;
  203. int minor = SDL_MINOR_VERSION;
  204. SDL_VERSION(&compiled);
  205. SDLTest_AssertCheck( compiled.major >= major,
  206. "SDL_VERSION() returned major %i (>= %i)",
  207. compiled.major,
  208. major);
  209. SDLTest_AssertCheck( compiled.minor >= minor,
  210. "SDL_VERSION() returned minor %i (>= %i)",
  211. compiled.minor,
  212. minor);
  213. return TEST_COMPLETED;
  214. }
  215. /* !
  216. * \brief Tests default SDL_Init
  217. */
  218. int platform_testDefaultInit(void *arg)
  219. {
  220. int ret;
  221. int subsystem;
  222. subsystem = SDL_WasInit(SDL_INIT_EVERYTHING);
  223. SDLTest_AssertCheck( subsystem != 0,
  224. "SDL_WasInit(0): returned %i, expected != 0",
  225. subsystem);
  226. ret = SDL_Init(SDL_WasInit(SDL_INIT_EVERYTHING));
  227. SDLTest_AssertCheck( ret == 0,
  228. "SDL_Init(0): returned %i, expected 0, error: %s",
  229. ret,
  230. SDL_GetError());
  231. return TEST_COMPLETED;
  232. }
  233. /* !
  234. * \brief Tests SDL_Get/Set/ClearError
  235. * \sa
  236. * http://wiki.libsdl.org/SDL_GetError
  237. * http://wiki.libsdl.org/SDL_SetError
  238. * http://wiki.libsdl.org/SDL_ClearError
  239. */
  240. int platform_testGetSetClearError(void *arg)
  241. {
  242. int result;
  243. const char *testError = "Testing";
  244. char *lastError;
  245. size_t len;
  246. SDL_ClearError();
  247. SDLTest_AssertPass("SDL_ClearError()");
  248. lastError = (char *)SDL_GetError();
  249. SDLTest_AssertPass("SDL_GetError()");
  250. SDLTest_AssertCheck(lastError != NULL,
  251. "SDL_GetError() != NULL");
  252. if (lastError != NULL)
  253. {
  254. len = SDL_strlen(lastError);
  255. SDLTest_AssertCheck(len == 0,
  256. "SDL_GetError(): no message expected, len: %i", (int) len);
  257. }
  258. result = SDL_SetError("%s", testError);
  259. SDLTest_AssertPass("SDL_SetError()");
  260. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  261. lastError = (char *)SDL_GetError();
  262. SDLTest_AssertCheck(lastError != NULL,
  263. "SDL_GetError() != NULL");
  264. if (lastError != NULL)
  265. {
  266. len = SDL_strlen(lastError);
  267. SDLTest_AssertCheck(len == SDL_strlen(testError),
  268. "SDL_GetError(): expected message len %i, was len: %i",
  269. (int) SDL_strlen(testError),
  270. (int) len);
  271. SDLTest_AssertCheck(SDL_strcmp(lastError, testError) == 0,
  272. "SDL_GetError(): expected message %s, was message: %s",
  273. testError,
  274. lastError);
  275. }
  276. /* Clean up */
  277. SDL_ClearError();
  278. SDLTest_AssertPass("SDL_ClearError()");
  279. return TEST_COMPLETED;
  280. }
  281. /* !
  282. * \brief Tests SDL_SetError with empty input
  283. * \sa
  284. * http://wiki.libsdl.org/SDL_SetError
  285. */
  286. int platform_testSetErrorEmptyInput(void *arg)
  287. {
  288. int result;
  289. const char *testError = "";
  290. char *lastError;
  291. size_t len;
  292. result = SDL_SetError("%s", testError);
  293. SDLTest_AssertPass("SDL_SetError()");
  294. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  295. lastError = (char *)SDL_GetError();
  296. SDLTest_AssertCheck(lastError != NULL,
  297. "SDL_GetError() != NULL");
  298. if (lastError != NULL)
  299. {
  300. len = SDL_strlen(lastError);
  301. SDLTest_AssertCheck(len == SDL_strlen(testError),
  302. "SDL_GetError(): expected message len %i, was len: %i",
  303. (int) SDL_strlen(testError),
  304. (int) len);
  305. SDLTest_AssertCheck(SDL_strcmp(lastError, testError) == 0,
  306. "SDL_GetError(): expected message '%s', was message: '%s'",
  307. testError,
  308. lastError);
  309. }
  310. /* Clean up */
  311. SDL_ClearError();
  312. SDLTest_AssertPass("SDL_ClearError()");
  313. return TEST_COMPLETED;
  314. }
  315. #if defined(HAVE_WFORMAT_OVERFLOW)
  316. #pragma GCC diagnostic push
  317. #pragma GCC diagnostic ignored "-Wformat-overflow"
  318. #endif
  319. /* !
  320. * \brief Tests SDL_SetError with invalid input
  321. * \sa
  322. * http://wiki.libsdl.org/SDL_SetError
  323. */
  324. int platform_testSetErrorInvalidInput(void *arg)
  325. {
  326. int result;
  327. const char *invalidError = NULL;
  328. const char *probeError = "Testing";
  329. char *lastError;
  330. size_t len;
  331. /* Reset */
  332. SDL_ClearError();
  333. SDLTest_AssertPass("SDL_ClearError()");
  334. /* Check for no-op */
  335. result = SDL_SetError("%s", invalidError);
  336. SDLTest_AssertPass("SDL_SetError()");
  337. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  338. lastError = (char *)SDL_GetError();
  339. SDLTest_AssertCheck(lastError != NULL,
  340. "SDL_GetError() != NULL");
  341. if (lastError != NULL)
  342. {
  343. len = SDL_strlen(lastError);
  344. SDLTest_AssertCheck(len == 0 || SDL_strcmp(lastError, "(null)") == 0,
  345. "SDL_GetError(): expected message len 0, was len: %i",
  346. (int) len);
  347. }
  348. /* Set */
  349. result = SDL_SetError("%s", probeError);
  350. SDLTest_AssertPass("SDL_SetError('%s')", probeError);
  351. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  352. /* Check for no-op */
  353. result = SDL_SetError("%s", invalidError);
  354. SDLTest_AssertPass("SDL_SetError(NULL)");
  355. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  356. lastError = (char *)SDL_GetError();
  357. SDLTest_AssertCheck(lastError != NULL,
  358. "SDL_GetError() != NULL");
  359. if (lastError != NULL)
  360. {
  361. len = SDL_strlen(lastError);
  362. SDLTest_AssertCheck(len == 0 || SDL_strcmp( lastError, "(null)" ) == 0,
  363. "SDL_GetError(): expected message len 0, was len: %i",
  364. (int) len);
  365. }
  366. /* Reset */
  367. SDL_ClearError();
  368. SDLTest_AssertPass("SDL_ClearError()");
  369. /* Set and check */
  370. result = SDL_SetError("%s", probeError);
  371. SDLTest_AssertPass("SDL_SetError()");
  372. SDLTest_AssertCheck(result == -1, "SDL_SetError: expected -1, got: %i", result);
  373. lastError = (char *)SDL_GetError();
  374. SDLTest_AssertCheck(lastError != NULL,
  375. "SDL_GetError() != NULL");
  376. if (lastError != NULL)
  377. {
  378. len = SDL_strlen(lastError);
  379. SDLTest_AssertCheck(len == SDL_strlen(probeError),
  380. "SDL_GetError(): expected message len %i, was len: %i",
  381. (int) SDL_strlen(probeError),
  382. (int) len);
  383. SDLTest_AssertCheck(SDL_strcmp(lastError, probeError) == 0,
  384. "SDL_GetError(): expected message '%s', was message: '%s'",
  385. probeError,
  386. lastError);
  387. }
  388. /* Clean up */
  389. SDL_ClearError();
  390. SDLTest_AssertPass("SDL_ClearError()");
  391. return TEST_COMPLETED;
  392. }
  393. #if defined(HAVE_WFORMAT_OVERFLOW)
  394. #pragma GCC diagnostic pop
  395. #endif
  396. /* !
  397. * \brief Tests SDL_GetPowerInfo
  398. * \sa
  399. * http://wiki.libsdl.org/SDL_GetPowerInfo
  400. */
  401. int platform_testGetPowerInfo(void *arg)
  402. {
  403. SDL_PowerState state;
  404. SDL_PowerState stateAgain;
  405. int secs;
  406. int secsAgain;
  407. int pct;
  408. int pctAgain;
  409. state = SDL_GetPowerInfo(&secs, &pct);
  410. SDLTest_AssertPass("SDL_GetPowerInfo()");
  411. SDLTest_AssertCheck(
  412. state==SDL_POWERSTATE_UNKNOWN ||
  413. state==SDL_POWERSTATE_ON_BATTERY ||
  414. state==SDL_POWERSTATE_NO_BATTERY ||
  415. state==SDL_POWERSTATE_CHARGING ||
  416. state==SDL_POWERSTATE_CHARGED,
  417. "SDL_GetPowerInfo(): state %i is one of the expected values",
  418. (int)state);
  419. if (state==SDL_POWERSTATE_ON_BATTERY)
  420. {
  421. SDLTest_AssertCheck(
  422. secs >= 0,
  423. "SDL_GetPowerInfo(): on battery, secs >= 0, was: %i",
  424. secs);
  425. SDLTest_AssertCheck(
  426. (pct >= 0) && (pct <= 100),
  427. "SDL_GetPowerInfo(): on battery, pct=[0,100], was: %i",
  428. pct);
  429. }
  430. if (state==SDL_POWERSTATE_UNKNOWN ||
  431. state==SDL_POWERSTATE_NO_BATTERY)
  432. {
  433. SDLTest_AssertCheck(
  434. secs == -1,
  435. "SDL_GetPowerInfo(): no battery, secs == -1, was: %i",
  436. secs);
  437. SDLTest_AssertCheck(
  438. pct == -1,
  439. "SDL_GetPowerInfo(): no battery, pct == -1, was: %i",
  440. pct);
  441. }
  442. /* Partial return value variations */
  443. stateAgain = SDL_GetPowerInfo(&secsAgain, NULL);
  444. SDLTest_AssertCheck(
  445. state==stateAgain,
  446. "State %i returned when only 'secs' requested",
  447. stateAgain);
  448. SDLTest_AssertCheck(
  449. secs==secsAgain,
  450. "Value %i matches when only 'secs' requested",
  451. secsAgain);
  452. stateAgain = SDL_GetPowerInfo(NULL, &pctAgain);
  453. SDLTest_AssertCheck(
  454. state==stateAgain,
  455. "State %i returned when only 'pct' requested",
  456. stateAgain);
  457. SDLTest_AssertCheck(
  458. pct==pctAgain,
  459. "Value %i matches when only 'pct' requested",
  460. pctAgain);
  461. stateAgain = SDL_GetPowerInfo(NULL, NULL);
  462. SDLTest_AssertCheck(
  463. state==stateAgain,
  464. "State %i returned when no value requested",
  465. stateAgain);
  466. return TEST_COMPLETED;
  467. }
  468. /* ================= Test References ================== */
  469. /* Platform test cases */
  470. static const SDLTest_TestCaseReference platformTest1 =
  471. { (SDLTest_TestCaseFp)platform_testTypes, "platform_testTypes", "Tests predefined types", TEST_ENABLED};
  472. static const SDLTest_TestCaseReference platformTest2 =
  473. { (SDLTest_TestCaseFp)platform_testEndianessAndSwap, "platform_testEndianessAndSwap", "Tests endianness and swap functions", TEST_ENABLED};
  474. static const SDLTest_TestCaseReference platformTest3 =
  475. { (SDLTest_TestCaseFp)platform_testGetFunctions, "platform_testGetFunctions", "Tests various SDL_GetXYZ functions", TEST_ENABLED};
  476. static const SDLTest_TestCaseReference platformTest4 =
  477. { (SDLTest_TestCaseFp)platform_testHasFunctions, "platform_testHasFunctions", "Tests various SDL_HasXYZ functions", TEST_ENABLED};
  478. static const SDLTest_TestCaseReference platformTest5 =
  479. { (SDLTest_TestCaseFp)platform_testGetVersion, "platform_testGetVersion", "Tests SDL_GetVersion function", TEST_ENABLED};
  480. static const SDLTest_TestCaseReference platformTest6 =
  481. { (SDLTest_TestCaseFp)platform_testSDLVersion, "platform_testSDLVersion", "Tests SDL_VERSION macro", TEST_ENABLED};
  482. static const SDLTest_TestCaseReference platformTest7 =
  483. { (SDLTest_TestCaseFp)platform_testDefaultInit, "platform_testDefaultInit", "Tests default SDL_Init", TEST_ENABLED};
  484. static const SDLTest_TestCaseReference platformTest8 =
  485. { (SDLTest_TestCaseFp)platform_testGetSetClearError, "platform_testGetSetClearError", "Tests SDL_Get/Set/ClearError", TEST_ENABLED};
  486. static const SDLTest_TestCaseReference platformTest9 =
  487. { (SDLTest_TestCaseFp)platform_testSetErrorEmptyInput, "platform_testSetErrorEmptyInput", "Tests SDL_SetError with empty input", TEST_ENABLED};
  488. static const SDLTest_TestCaseReference platformTest10 =
  489. { (SDLTest_TestCaseFp)platform_testSetErrorInvalidInput, "platform_testSetErrorInvalidInput", "Tests SDL_SetError with invalid input", TEST_ENABLED};
  490. static const SDLTest_TestCaseReference platformTest11 =
  491. { (SDLTest_TestCaseFp)platform_testGetPowerInfo, "platform_testGetPowerInfo", "Tests SDL_GetPowerInfo function", TEST_ENABLED };
  492. /* Sequence of Platform test cases */
  493. static const SDLTest_TestCaseReference *platformTests[] = {
  494. &platformTest1,
  495. &platformTest2,
  496. &platformTest3,
  497. &platformTest4,
  498. &platformTest5,
  499. &platformTest6,
  500. &platformTest7,
  501. &platformTest8,
  502. &platformTest9,
  503. &platformTest10,
  504. &platformTest11,
  505. NULL
  506. };
  507. /* Platform test suite (global) */
  508. SDLTest_TestSuiteReference platformTestSuite = {
  509. "Platform",
  510. NULL,
  511. platformTests,
  512. NULL
  513. };