Fixed compilation issues.
Fixed test.