您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
 
 
 
 
 
 

47 行
1.1 KiB

  1. /*
  2. * caca-test testsuite program for libcaca
  3. * Copyright (c) 2008 Sam Hocevar <samhocevar.net>
  4. * All Rights Reserved
  5. *
  6. * This program is free software. It comes without any warranty, to
  7. * the extent permitted by applicable law. You can redistribute it
  8. * and/or modify it under the terms of the Do What The Fuck You Want
  9. * To Public License, Version 2, as published by Sam Hocevar. See
  10. * http://sam.zoy.org/wtfpl/COPYING for more details.
  11. */
  12. #include "config.h"
  13. #include <cppunit/extensions/HelperMacros.h>
  14. #include <cppunit/TestCaller.h>
  15. #include <cppunit/TestCase.h>
  16. #include <cppunit/TestSuite.h>
  17. #include "caca.h"
  18. class DriverTest : public CppUnit::TestCase
  19. {
  20. CPPUNIT_TEST_SUITE(DriverTest);
  21. CPPUNIT_TEST(test_list);
  22. CPPUNIT_TEST_SUITE_END();
  23. public:
  24. DriverTest() : CppUnit::TestCase("Driver Test") {}
  25. void setUp() {}
  26. void tearDown() {}
  27. void test_list()
  28. {
  29. char const * const * list;
  30. list = caca_get_display_driver_list();
  31. CPPUNIT_ASSERT(list != NULL);
  32. CPPUNIT_ASSERT(list[0] != NULL);
  33. }
  34. };
  35. CPPUNIT_TEST_SUITE_REGISTRATION(DriverTest);