Fix ec2 unit test