diff --git a/data/index.html b/data/index.html index bfaf037b..9611abb0 100644 --- a/data/index.html +++ b/data/index.html @@ -10,7 +10,7 @@ ERROR: JavaScript need to be enabled for the coverage report to work. - + diff --git a/src/writers/html-writer.cc b/src/writers/html-writer.cc index dffc9eeb..d6627388 100644 --- a/src/writers/html-writer.cc +++ b/src/writers/html-writer.cc @@ -141,7 +141,7 @@ class HtmlWriter : public WriterBase unsigned int nTotalCodeLines = 0; // Out-file for JSON data - std::ofstream outJson(m_outDirectory + "index.json"); + std::ofstream outJson(m_outDirectory + "index.js"); outJson << "var data = {files:[\n"; // Not really json, but anyway for (FileMap_t::const_iterator it = m_files.begin(); @@ -233,7 +233,7 @@ class HtmlWriter : public WriterBase dir = opendir(idx.c_str()); panic_if(!dir, "Can't open directory %s\n", idx.c_str()); - std::ofstream outJson(m_indexDirectory + "index.json"); + std::ofstream outJson(m_indexDirectory + "index.js"); outJson << "var data = {files:[\n"; std::string merged; diff --git a/src/writers/writer-base.cc b/src/writers/writer-base.cc index a40c672e..e9523241 100644 --- a/src/writers/writer-base.cc +++ b/src/writers/writer-base.cc @@ -56,7 +56,7 @@ WriterBase::File::File(const std::string &filename) : readFile(filename); m_outFileName = fmt("%s.%x.html", m_fileName.c_str(), m_crc); - m_jsonOutFileName = fmt("%s.%x.json", m_fileName.c_str(), m_crc); + m_jsonOutFileName = fmt("%s.%x.js", m_fileName.c_str(), m_crc); } void WriterBase::File::readFile(const std::string &filename)