add test for initialize method and add attr_reader to code so that this test is possible