Style fixes.
Added compatibility tests for port operations.