You have to implement mock callouts for this .In test class the actual call wont be made and hence mock interface you can use to achieve code coverage.
refer this thread :Testing WebServiceCallout with HttpCalloutMock
caution:Testing HttpCallout with HttpCalloutMock and UnitTest Created Data
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_restful_http_testing_httpcalloutmock.htm
You have to implement mock callouts for this .In test class the actual call wont be made and hence mock interface you can use to achieve code coverage.
refer this thread :Testing WebServiceCallout with HttpCalloutMock
caution:Testing HttpCallout with HttpCalloutMock and UnitTest Created Data
There is known issue of Pending DML statements
Refer the blog:
http://blogs.developerforce.com/developer-relations/2012/10/testing-http-callouts-with-static-data-in-winter-13.html#comment-688228232
http://salesforce.stackexchange.com/questions/8523/test-class-for-xml-dom-document-webservices
Regards,
Ashish