[Training Video - 6] [File Reading] [Groovy] Reading Properties file

Reading Properties file :

Properties prop = new Properties()
def path = "D:\\SoapUIStudy\\application.properties"
FileInputStream fs = new FileInputStream(path)
prop.load(fs)
log.info prop.getProperty("name")

 Result :

Tue Jun 16 15:12:38 CST 2015:INFO:soapUI

posted on 2015-06-16 15:15  张缤分  阅读(188)  评论(0)    收藏  举报

导航