[render-test] No camelCase on the metrics.json tag
It is ugly.
@@ -274,9 +274,9 @@ std::string serializeMetrics(const TestMetrics& metrics) {
|
||||
|
||||
writer.StartObject();
|
||||
|
||||
// Start fileSize section.
|
||||
// Start file-size section.
|
||||
if (!metrics.fileSize.empty()) {
|
||||
writer.Key("fileSize");
|
||||
writer.Key("file-size");
|
||||
writer.StartArray();
|
||||
for (const auto& fileSizeProbe : metrics.fileSize) {
|
||||
assert(!fileSizeProbe.first.empty());
|
||||
@@ -460,8 +460,8 @@ TestMetrics readExpectedMetrics(const mbgl::filesystem::path& path) {
|
||||
|
||||
const auto& document = maybeJson.get<mbgl::JSDocument>();
|
||||
|
||||
if (document.HasMember("fileSize")) {
|
||||
const mbgl::JSValue& fileSizeValue = document["fileSize"];
|
||||
if (document.HasMember("file-size")) {
|
||||
const mbgl::JSValue& fileSizeValue = document["file-size"];
|
||||
assert(fileSizeValue.IsArray());
|
||||
for (auto& probeValue : fileSizeValue.GetArray()) {
|
||||
assert(probeValue.IsArray());
|
||||
|
||||
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"fileSize": [
|
||||
"file-size": [
|
||||
[
|
||||
"image",
|
||||
"expected.aaa",
|
||||
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"fileSize": [
|
||||
"file-size": [
|
||||
[
|
||||
"image",
|
||||
"expected.png",
|
||||
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"fileSize": [
|
||||
"file-size": [
|
||||
[
|
||||
"image",
|
||||
"expected.png",
|
||||
|
Before Width: | Height: | Size: 169 B After Width: | Height: | Size: 169 B |
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"fileSize": [
|
||||
"file-size": [
|
||||
[
|
||||
"image",
|
||||
"expected.png",
|
||||
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"tests/filesize/fail-size-is-over": "Should fail, size is bigger than expected.",
|
||||
"tests/filesize/fail-size-is-under": "Should fail, size is smaller than expected.",
|
||||
"tests/filesize/fail-file-doesnt-match": "Should fail, doesn't match the expectation.",
|
||||
"tests/filesize/fail-file-not-found": "Should fail, file not found."
|
||||
"tests/file-size/fail-size-is-over": "Should fail, size is bigger than expected.",
|
||||
"tests/file-size/fail-size-is-under": "Should fail, size is smaller than expected.",
|
||||
"tests/file-size/fail-file-doesnt-match": "Should fail, doesn't match the expectation.",
|
||||
"tests/file-size/fail-file-not-found": "Should fail, file not found."
|
||||
}
|
||||
|
||||