Added resource for invalid branch
Added test for invalid branch