@Override
    public long getStateSize() {
        return jobManagerOwnedSnapshot != null ? jobManagerOwnedSnapshot.getStateSize() : 0L;
    }
@Test
    void getStateSize() {
        long size = 42L;

        SnapshotResult<StateObject> result =
                SnapshotResult.withLocalState(
                        new DummyStateObject(size), new DummyStateObject(size));
        assertThat(result.getStateSize()).isEqualTo(size);
    }