
add_executable(test_plib_optionparser_string main.cpp)
target_link_libraries(test_plib_optionparser_string phoenix_option_parser)

add_test(NAME TestOptionParserStringLong
	COMMAND ${CMAKE_CURRENT_BINARY_DIR}/test_plib_optionparser_string --input=fileName.txt
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)

add_test(NAME TestOptionParserStringShort
	COMMAND ${CMAKE_CURRENT_BINARY_DIR}/test_plib_optionparser_string -i fileName.txt
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)
	
add_executable(test_plib_optionparser_longstring main_longString.cpp)
target_link_libraries(test_plib_optionparser_longstring phoenix_option_parser)

# This way of cmake to escape arguments is a realy pain in the ass !!!!!!!
add_test(NAME TestOptionParserLongStringLong
	COMMAND ${CMAKE_CURRENT_BINARY_DIR}/test_plib_optionparser_longstring "--input=one long string option"
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)

add_test(NAME TestOptionParserLongStringShort
	COMMAND ${CMAKE_CURRENT_BINARY_DIR}/test_plib_optionparser_longstring -i "one long string option"
	WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
)

