Fix-up BOM issues, add unit tests for Line