public void assertNodes(String explanation, int nodes, int groups,
                            double vcpu, double memory, double disk, double bandwidth,
                            DiskSpeed diskSpeed, StorageType storageType,
                            ApplicationId app, ClusterSpec cluster) {
        List<Node> nodeList = nodeRepository.nodes().list().owner(app).cluster(cluster.id()).state(Node.State.active).not().retired().asList();
        assertEquals(explanation + ": Node count",
                     nodes,
                     nodeList.size());
        assertEquals(explanation + ": Group count",
                     groups,
                     nodeList.stream().map(n -> n.allocation().get().membership().cluster().group().get()).distinct().count());
        for (Node node : nodeList) {
            var expected = new NodeResources(vcpu, memory, disk, bandwidth, diskSpeed, storageType);
            assertTrue(explanation + ": Resources: Expected " + expected + " but was " + node.resources(),
                       expected.justNonNumbers().compatibleWith(node.resources().justNonNumbers()));
            assertEquals(explanation + ": Vcpu: Expected " + expected.vcpu() + " but was " + node.resources().vcpu(),
                         expected.vcpu(), node.resources().vcpu(), 0.05);
            assertEquals(explanation + ": Memory: Expected " + expected.memoryGiB() + " but was " + node.resources().memoryGiB(),
                         expected.memoryGiB(), node.resources().memoryGiB(), 0.05);
            assertEquals(explanation + ": Disk: Expected " + expected.diskGb() + " but was " + node.resources().diskGb(),
                         expected.diskGb(), node.resources().diskGb(), 0.05);
        }
    }
Assert on the current *non retired* nodes
node-repository/src/test/java/com/yahoo/vespa/hosted/provision/provisioning/ProvisioningTester.java