It could be very handy to know how and where to read MAF logging output from iOS simulator. This is not that obvious to find logging output on Mac OS system. All log is written into application.log file, this file is located inside temporary application directory. I will explain how to locate this directory and how to open application.log file. You can read more about MAF testing and logging here - 18.5 Using and Configuring Logging.
Sample mobile application - ADFMobileLogginApp.zip, is pretty basic and contains System.out.println to write a message into application.log file:
Message is written to the log from Action Listener method, invoked from Save button. Log file application.log is accessible from the following location (you can access it from the console) -
Users/youruser/Library/Application Support/iPhone/ 7.1/Applications/com.company.ADFMobileLoggingApp/Document/logs.
As you can see, application.log file is stored under logs directory in documents folder. You must navigate to the iOS simulator, application temporary folder to access it:
There will be application.log file available:
Log file can be opened directly from console, execute command open -a TextEdit application.log:
Message from saveAction() is printed in the log:
Enjoy MAF coding in Mac OS !
Sample mobile application - ADFMobileLogginApp.zip, is pretty basic and contains System.out.println to write a message into application.log file:
Message is written to the log from Action Listener method, invoked from Save button. Log file application.log is accessible from the following location (you can access it from the console) -
Users/youruser/Library/Application Support/iPhone/ 7.1/Applications/com.company.ADFMobileLoggingApp/Document/logs.
As you can see, application.log file is stored under logs directory in documents folder. You must navigate to the iOS simulator, application temporary folder to access it:
There will be application.log file available:
Log file can be opened directly from console, execute command open -a TextEdit application.log:
Message from saveAction() is printed in the log:
Enjoy MAF coding in Mac OS !