Fix test with resource change