Update db schema of roles.

ProductRole is useless, so remove it.

Add unique index for other roles.

Change-Id: Ic4fa024e09e666955a5c3b95e163a7c621b2f530
Fixes: #1962
Test gittree changes for importing scm script

Test addtion, deletion, update for gittree

Change-Id: I695c20398ad98fb557ee66751554579f6d23e8ef
Change test cases to use join to select objects.

Django query set can use two underscores(__) to refer fields
in foreign key relationship.

Change-Id: I2ff5b876879b0203351337cf7cbbdc56dd207333
Extract GitTree testing and use join select objects

To make file with less code, seperate kinds of entries testing in
different files.

Change-Id: I09ece3fc95b5ad51d9bb76daa5135c805f86a3dc
Test GitTreeRole changes for importing scm script

Test addition, deletion, update, transform for GitTreeRole

Change-Id: I864b43d206d9315275d94f7f1253c299b80f75e6
Test SubDomainRole changes for importing scm script

Test addition, deletion, update, transform for SubDomainRole

Change-Id: Ia481507113b9c579f9cff45ccbc1104e7f446b31
Clear testing import scm script

Make related testing in one file

Change-Id: I7e3dae1cfbdb5f3ba32bb959354851414fd2498d