{"action":"created","issue":{"url":"https://api.github.com/repos/garris/BackstopJS/issues/92","labels_url":"https://api.github.com/repos/garris/BackstopJS/issues/92/labels{/name}","comments_url":"https://api.github.com/repos/garris/BackstopJS/issues/92/comments","events_url":"https://api.github.com/repos/garris/BackstopJS/issues/92/events","html_url":"https://github.com/garris/BackstopJS/issues/92","id":106566502,"number":92,"title":"Backstop.js behind a proxy (fetaure: casper add CLI configs to backstop.json)","user":{"login":"klausbayrhammer","id":1397470,"avatar_url":"https://avatars.githubusercontent.com/u/1397470?v=3","gravatar_id":"","url":"https://api.github.com/users/klausbayrhammer","html_url":"https://github.com/klausbayrhammer","followers_url":"https://api.github.com/users/klausbayrhammer/followers","following_url":"https://api.github.com/users/klausbayrhammer/following{/other_user}","gists_url":"https://api.github.com/users/klausbayrhammer/gists{/gist_id}","starred_url":"https://api.github.com/users/klausbayrhammer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/klausbayrhammer/subscriptions","organizations_url":"https://api.github.com/users/klausbayrhammer/orgs","repos_url":"https://api.github.com/users/klausbayrhammer/repos","events_url":"https://api.github.com/users/klausbayrhammer/events{/privacy}","received_events_url":"https://api.github.com/users/klausbayrhammer/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/garris/BackstopJS/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/garris/BackstopJS/labels/help%20wanted","name":"help wanted","color":"159818"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-09-15T14:20:15Z","updated_at":"2015-10-26T18:44:49Z","closed_at":null,"body":"We currently use backstop (with slimer) behind a proxy. There are CLI arguments in casper to control the proxy config but I haven't found a way to pass these parameters from backstop to casper and slimer. A sample casperjs call would be:\r\n`casperjs --engine=slimerjs --proxy-type=http --proxy=proxyIp:port --proxy-auth=user:pass casperScript.js`\r\n\r\nIs there a way to specify these proxy parameters (or even all casper parameters) in backstop?"},"comment":{"url":"https://api.github.com/repos/garris/BackstopJS/issues/comments/151244557","html_url":"https://github.com/garris/BackstopJS/issues/92#issuecomment-151244557","issue_url":"https://api.github.com/repos/garris/BackstopJS/issues/92","id":151244557,"user":{"login":"garris","id":447033,"avatar_url":"https://avatars.githubusercontent.com/u/447033?v=3","gravatar_id":"","url":"https://api.github.com/users/garris","html_url":"https://github.com/garris","followers_url":"https://api.github.com/users/garris/followers","following_url":"https://api.github.com/users/garris/following{/other_user}","gists_url":"https://api.github.com/users/garris/gists{/gist_id}","starred_url":"https://api.github.com/users/garris/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/garris/subscriptions","organizations_url":"https://api.github.com/users/garris/orgs","repos_url":"https://api.github.com/users/garris/repos","events_url":"https://api.github.com/users/garris/events{/privacy}","received_events_url":"https://api.github.com/users/garris/received_events","type":"User","site_admin":false},"created_at":"2015-10-26T18:44:49Z","updated_at":"2015-10-26T18:44:49Z","body":"@klausbayrhammer, @paweltin \r\nI just looked at this.   It looks like the approach, which I suggested originally, may be un-necessarily over-built.\r\n\r\nAsking the user to split the property and value out is probably unnecessary.   All we are doing is reassembling the data (adding unnecessary complexity) -- unless we are going to actually use this data internally we are probably better off simply asking the user to add a simple array of string-formatted properties.  e.g.   `casperFlags: [\"--engine=slimerjs\", \"proxy-type=http\", ...]`\r\n\r\nI think this updated approach is maybe better.  It gives the user more control and reduces our code complexity.  We then simply do `if (paths.casperFlags) {args = paths.casperFlags}` on [line 52](https://github.com/garris/BackstopJS/blob/master/gulp/tasks/test.js#L52).   This would also conveniently over-ride the `paths.engine` line that comes before.   Additionally, we could merge the `paths.engine` values (with the `casperFlags` array taking precedence for better compatibility/predictability.)\r\n\r\n\r\nPlease send some feedback, what do you guys think?  Is there any benefit to the original suggestion over this one?   \r\n\r\nThanks."}}