Multigate base class and tests.
Finished multigates and tests.
Merge with multigates.