[render-test] Add test for file size tolerance

This commit is contained in:
Thiago Marcos P. Santos
2019-10-13 18:37:39 +03:00
parent 8b3a222c81
commit 465d4e8cfa
6 changed files with 92 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 169 B

View File

@@ -0,0 +1,14 @@
{
"file-size": [
[
"image",
"expected.png",
177
],
[
"style",
"style.json",
548
]
]
}

View File

@@ -0,0 +1,32 @@
{
"version": 8,
"metadata": {
"test": {
"operations": [
["probeFileSize", "style", "style.json", 0.05],
["probeFileSize", "image", "expected.png", 0.05]
],
"width": 64,
"height": 64
}
},
"sources": {
"geojson": {
"type": "geojson",
"data": {
"type": "Point",
"coordinates": [
0,
0
]
}
}
},
"layers": [
{
"id": "circle",
"type": "circle",
"source": "geojson"
}
]
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 169 B

View File

@@ -0,0 +1,14 @@
{
"file-size": [
[
"image",
"expected.png",
161
],
[
"style",
"style.json",
498
]
]
}

View File

@@ -0,0 +1,32 @@
{
"version": 8,
"metadata": {
"test": {
"operations": [
["probeFileSize", "style", "style.json", 0.05],
["probeFileSize", "image", "expected.png", 0.05]
],
"width": 64,
"height": 64
}
},
"sources": {
"geojson": {
"type": "geojson",
"data": {
"type": "Point",
"coordinates": [
0,
0
]
}
}
},
"layers": [
{
"id": "circle",
"type": "circle",
"source": "geojson"
}
]
}