Example #1
0
def test_generate_auth_certificates(paths, overwrite_cert, results):
	"""
	Testing auto-Generation and auto-validation of CURVE ZMQ keys/certificates 
	"""
	try:
		if overwrite_cert: logger.warning('Overwriting ZMQ Authentication certificates over previous ones!')
		output = generate_auth_certificates(paths, overwrite = overwrite_cert)
		if paths != 'wrong_test_path':
			assert bool(output) == results
	except Exception as e:
		if paths == 'wrong_test_path':
			pass
		else:
			pytest.fail(str(e))
Example #2
0
def test_generate_auth_certificates(paths, overwrite_cert, results):
    """
    Testing auto-Generation and auto-validation of CURVE ZMQ keys/certificates
    """
    try:
        if overwrite_cert:
            logger.warning(
                "Overwriting ZMQ Authentication certificates over previous ones!"
            )
        output = generate_auth_certificates(paths,
                                            overwrite=overwrite_cert,
                                            logging=True)
        assert bool(output) == results
    except Exception as e:
        pytest.fail(str(e))