Fixed flaky SlaveTest.KillTaskBetweenRunTaskParts test.

Moving EXPECT_CALL(removeFramework) before killTask() removes a race,
which made the expected call occur before it is expected.

Review: https://reviews.apache.org/r/26929