tillrohrmann commented on a change in pull request #7662: [FLINK-10431]
Extraction of scheduling-related code from SlotPool into preliminary Scheduler
(rebased)
URL: https://github.com/apache/flink/pull/7662#discussion_r255154699
##########
File path:
flink-runtime/src/test/java/org/apache/flink/runtime/executiongraph/ExecutionGraphMetricsTest.java
##########
@@ -66,11 +74,13 @@ public void testExecutionGraphRestartTimeMetric() throws
JobException, IOExcepti
jobVertex.setInvokableClass(NoOpInvokable.class);
JobGraph jobGraph = new JobGraph("Test Job", jobVertex);
+ Scheduler scheduler = mock(Scheduler.class);
Review comment:
Rather than starting with mocking I would suggest to extract an interface
from `Scheduler` and add a `TestingSchedulerImpl` where we can control the
behaviour for `allocateSlot`. Take a look at `TestingJobMasterGateway`, for
example.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services