Add getter and setter methods for _event_context in CLI

Also fix the corresponding integration tests
Add getter and setter methods for _client in CLI
Merge pull request #3114 from sbesson/12388_getter

CLI: add getter/setters for client/event context