Added test cases for extractAttributes.