aboutsummaryrefslogtreecommitdiffhomepage
path: root/dm/DMUtil.cpp
blob: 803c338adce932fd3f1244a9af4609bff75ca92e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#include "DMUtil.h"

namespace DM {

SkString underJoin(const char* a, const char* b) {
    SkString s;
    s.appendf("%s_%s", a, b);
    return s;
}

SkString png(SkString s) {
    s.appendf(".png");
    return s;
}

bool meetsExpectations(const skiagm::Expectations& expectations,
                       const skiagm::GmResultDigest& digest) {
    return expectations.ignoreFailure()
        || expectations.empty()
        || expectations.match(digest);
}

}  // namespace DM