database - JUnit to connect to Oracle DB from Jenkins -


i connect actual physical database junit, while runs jenkins during maven build/test. using jboss writing junit. don't want store db connection string within junit code/git/svn. rather externalize either via datasource , connect using jndi in runtime or other mechanism. there way, can use datasource setup in jenkins connect db or there better approach achieve this? basically, want hide connection id/pwd developers well, don't know/see.

you can use environment variables or system properties provide configuration jenkins junit test. read them in test , use establish connection db.


Comments

Popular posts from this blog

'hasOwnProperty' in javascript -

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -

How to understand 2 main() functions after using uftrace to profile the C++ program? -