Add unittest for file