If you are using Force.com Email Services, you may be working with attachments from your inbound emails. Consequently, it makes sense to learn how to test these in a test method and create inline attachments for the tests.

Here is an example of how you can create an attachment from your inbound emails using the Force.com Email Services. You might have to modify the code to fit your needs, but it should serve as a good starting point:

static testMethod void myTestMethod() {

   // Create a new email, envelope object and Attachment
   Messaging.InboundEmail email = new Messaging.InboundEmail();
   Messaging.InboundEnvelope env = new Messaging.InboundEnvelope();
   Messaging.InboundEmail.BinaryAttachment inAtt = new Messaging.InboundEmail.BinaryAttachment();

   email.subject = 'test';
   env.fromAddress = 'user@acme.com';

   // set the body of the attachment
   inAtt.body = blob.valueOf('test');
   inAtt.fileName = 'my attachment name';
   inAtt.mimeTypeSubType = 'plain/txt';

   email.binaryAttachments = new Messaging.inboundEmail.BinaryAttachment[] {inAtt }; 

   // call the class and test it with the data in the testMethod
   myTestObj emailServiceObj = new myTestObj();
   emailServiceObj.handleInboundEmail(email, env );