added line model and rspec tests'