add test with self-signed certificate