mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-20 23:53:13 +09:00
Don't write input stats to both input and output (#734)
This commit is contained in:
1 parent
26269df7d4
commit
7b8945ff15
2 files changed
+11
-1
No files matched your search
@@ -98,7 +98,7 @@ function setForceFlowStatistic(
|
|||||||
statisticName,
|
statisticName,
|
||||||
reverseDirection,
|
reverseDirection,
|
||||||
item
|
item
|
||||||
).set(value);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -66,9 +66,19 @@ describe("statistics_exporter plugin", function() {
|
|||||||
assert.equal(instance._instanceForceFlowStatistics.labels(
|
assert.equal(instance._instanceForceFlowStatistics.labels(
|
||||||
"7357", "nauvis", "player", "item_production_statistics", "input", "inserter").get(),
|
"7357", "nauvis", "player", "item_production_statistics", "input", "inserter").get(),
|
||||||
10);
|
10);
|
||||||
|
assert.equal(instance._instanceForceFlowStatistics.labels(
|
||||||
|
"7357", "nauvis", "player", "item_production_statistics", "output", "iron-plate").get(),
|
||||||
|
24);
|
||||||
|
// Assert that it didn't record inserter consumption as production
|
||||||
|
assert.equal(instance._instanceForceFlowStatistics.labels(
|
||||||
|
"7357", "nauvis", "player", "item_production_statistics", "output", "inserter").get(),
|
||||||
|
0);
|
||||||
assert.equal(instance._instanceGameFlowStatistics.labels(
|
assert.equal(instance._instanceGameFlowStatistics.labels(
|
||||||
"7357", "nauvis", "pollution_statistics", "input", "boiler").get(),
|
"7357", "nauvis", "pollution_statistics", "input", "boiler").get(),
|
||||||
2000);
|
2000);
|
||||||
|
assert.equal(instance._instanceGameFlowStatistics.labels(
|
||||||
|
"7357", "nauvis", "pollution_statistics", "output", "tree-proxy").get(),
|
||||||
|
560);
|
||||||
assert.equal(instance._instancePlatformMapping.labels(
|
assert.equal(instance._instancePlatformMapping.labels(
|
||||||
"7357", "platform-1", "player", "nauvis").get(),
|
"7357", "platform-1", "player", "nauvis").get(),
|
||||||
1);
|
1);
|
||||||
|
|||||||
Reference in new issue
Block a user