remove DMJsonWriter::AddTestFailure
As far as I can tell, Gold doesn't do anything with this information. The bots go red if any unit test fails... no need to log it long-term. Change-Id: Iae9ddd61c0a7d37437bb93441e83948c2e518b42 Reviewed-on: https://skia-review.googlesource.com/c/skia/+/206940 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Mike Klein <mtklein@google.com>
This commit is contained in:
parent
42cbedd3c7
commit
de8362c6f2
@ -1382,7 +1382,6 @@ static void run_test(skiatest::Test test, const GrContextOptions& grCtxOptions)
|
||||
struct : public skiatest::Reporter {
|
||||
void reportFailed(const skiatest::Failure& failure) override {
|
||||
fail(failure.toString());
|
||||
JsonWriter::AddTestFailure(failure);
|
||||
}
|
||||
bool allowExtendedTest() const override {
|
||||
return FLAGS_pathOpsExtended;
|
||||
|
@ -27,14 +27,6 @@ void JsonWriter::AddBitmapResult(const BitmapResult& result) {
|
||||
gBitmapResults.push_back(result);
|
||||
}
|
||||
|
||||
SkTArray<skiatest::Failure> gFailures;
|
||||
SK_DECLARE_STATIC_MUTEX(gFailureLock);
|
||||
|
||||
void JsonWriter::AddTestFailure(const skiatest::Failure& failure) {
|
||||
SkAutoMutexAcquire lock(gFailureLock);
|
||||
gFailures.push_back(failure);
|
||||
}
|
||||
|
||||
void JsonWriter::DumpJson(const char* dir,
|
||||
CommandLineFlags::StringArray key,
|
||||
CommandLineFlags::StringArray properties) {
|
||||
@ -98,24 +90,6 @@ void JsonWriter::DumpJson(const char* dir,
|
||||
writer.endArray(); // results
|
||||
}
|
||||
|
||||
{
|
||||
SkAutoMutexAcquire lock(gFailureLock);
|
||||
if (gFailures.count() > 0) {
|
||||
writer.beginObject("test_results");
|
||||
writer.beginArray("failures");
|
||||
for (int i = 0; i < gFailures.count(); i++) {
|
||||
writer.beginObject();
|
||||
writer.appendString("file_name", gFailures[i].fileName);
|
||||
writer.appendS32 ("line_no" , gFailures[i].lineNo);
|
||||
writer.appendString("condition", gFailures[i].condition);
|
||||
writer.appendString("message" , gFailures[i].message.c_str());
|
||||
writer.endObject(); // 1 failure
|
||||
}
|
||||
writer.endArray(); // failures
|
||||
writer.endObject(); // test_results
|
||||
}
|
||||
}
|
||||
|
||||
writer.endObject(); // root
|
||||
writer.flush();
|
||||
stream.flush();
|
||||
|
@ -10,7 +10,6 @@
|
||||
|
||||
#include "CommandLineFlags.h"
|
||||
#include "SkString.h"
|
||||
#include "Test.h"
|
||||
|
||||
namespace DM {
|
||||
|
||||
@ -42,11 +41,6 @@ public:
|
||||
*/
|
||||
static void AddBitmapResult(const BitmapResult&);
|
||||
|
||||
/**
|
||||
* Add a Failure from a Test.
|
||||
*/
|
||||
static void AddTestFailure(const skiatest::Failure&);
|
||||
|
||||
/**
|
||||
* Write all collected results to the file dir/dm.json.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user