public void addMemMeasurements(double value, int count) {
        var idealLoad = fixture.clusterModel().idealLoad();
        NodeList nodes = fixture.nodes();
        float oneExtraNodeFactor = (float)(nodes.size() - 1.0) / (nodes.size());
        Load load = new Load(idealLoad.cpu(), value, idealLoad.disk(), 0, 0).multiply(oneExtraNodeFactor);
        for (int i = 0; i < count; i++) {
            fixture.tester().clock().advance(samplingInterval);
            for (Node node : nodes) {
                fixture.tester().nodeMetricsDb().addNodeMetrics(List.of(new Pair<>(node.hostname(),
                                                                        new NodeMetricSnapshot(fixture.tester().clock().instant(),
                                                                                               load,
                                                                                               0,
                                                                                               true,
                                                                                               true,
                                                                                               0.0))));
            }
        }
    }
Adds measurements with the given resource value and ideal values for the other resources,
scaled to take one node redundancy into account.
(I.e we adjust to measure a bit lower load than "naively" wanted to offset for the autoscaler
wanting to see the ideal load with one node missing.)
node-repository/src/test/java/com/yahoo/vespa/hosted/provision/autoscale/Loader.java