Add unittest for detach interface with no local port id case

1. Fix the previous unittest issue
2. Add test case to check no local port id found

Change-Id: I95674b45a6db64359a1d8a47bfc5aa367ab8594d
Merge "Add unittest for detach interface with no local port id case" into stable/juno