cmParseBlanketJSCoverage.h 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /*============================================================================
  2. CMake - Cross Platform Makefile Generator
  3. Copyright 2000-2009 Kitware, Inc.
  4. Distributed under the OSI-approved BSD License (the "License");
  5. see accompanying file Copyright.txt for details.
  6. This software is distributed WITHOUT ANY WARRANTY; without even the
  7. implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  8. See the License for more information.
  9. ============================================================================*/
  10. #ifndef cmParseBlanketJSCoverage_h
  11. #define cmParseBlanketJSCoverage_h
  12. #include "cmStandardIncludes.h"
  13. #include "cmCTestCoverageHandler.h"
  14. /** \class cmParseBlanketJSCoverage
  15. * \brief Parse BlanketJS coverage information
  16. *
  17. * This class is used to parse BlanketJS(Pascal) coverage information
  18. * generated by the Blanket.js library when used in conjunction with the
  19. * test runner mocha.js, which is used to write out the JSON format.
  20. *
  21. * Blanket.js:
  22. * http://blanketjs.org/
  23. *
  24. * Mocha.js
  25. * http://visionmedia.github.io/mocha/
  26. */
  27. class cmParseBlanketJSCoverage
  28. {
  29. public:
  30. cmParseBlanketJSCoverage(cmCTestCoverageHandlerContainer& cont,
  31. cmCTest* ctest);
  32. bool LoadCoverageData(std::vector<std::string> files);
  33. // Read the JSON output
  34. bool ReadJSONFile(std::string file);
  35. protected:
  36. class JSONParser;
  37. cmCTestCoverageHandlerContainer& Coverage;
  38. cmCTest* CTest;
  39. };
  40. #endif