added more tests and added ncgetatt function