Hi,
I think you are having 2 completely different problems.
The first problem, "Error: Error opening attachment file \\servername\testdir\test.xls".
This one only means that most probably the UNC path was not recognized, for some reason. Probably \\servername could not be used, or lack of authorizations from the batch user to \\servername\testdir\test.xls.
The second error, could be related to this, on an attempt to use Oulook to send the email: https://support.microsoft.com/en-us/kb/2968977
But I think it might be better to ask your administrator or technical support.
Anyway, in order to send emails and attachments, you can always use free sofware run with x commands, as blat or similar.