Adding get metadata and test.