Fixing trailing new line, updating test

Adding an assertion