private static CPUResource getCpuCores(final Configuration config) {
        return getCpuCoresWithFallback(config, -1.0);
    }
@Test
    void testConfigCpuCores() {
        final double cpuCores = 1.0;

        Configuration conf = new Configuration();
        conf.set(TaskManagerOptions.CPU_CORES, cpuCores);

        validateInAllConfigurations(
                conf,
                taskExecutorProcessSpec ->
                        assertThat(taskExecutorProcessSpec.getCpuCores())
                                .isEqualTo(new CPUResource(cpuCores)));
    }