pam_unix accept the password passed by your module, but the problem is that you use:
auth required pam_unix.so
After this module is successed pam will call the module on the next line. pam_deny.so is a module which return a failure for every call. It's possible to specify that the next line must be skipped if the module return success. You can do that using this:
auth [success=1 default=ignore] pam_unix.so try_first_pass nullok_secure debug
In this instance, if the module return success it skips the next "1" line.
Use this to solve the problem:
auth sufficient libtest-pam-auth-module.so
auth [success=1 default=ignore] pam_unix.so try_first_pass nullok_secure debug
auth requisite pam_deny.so
auth required pam_permit.so
auth optional pam_cap.so