'use strict';

exports.config = (function() {

    var profile = process.env.PROTRACTOR_PROFILE;
    console.log('protractor profile: ' + profile);

    var extra;
    switch (profile) {
        case undefined:
            extra = {
                capabilities: {
                    'browserName': 'chrome'
                },
                chromeOnly: true
            };
            break;
        case 'phantomjs':
            extra = {
                capabilities: {
                   'browserName': 'phantomjs',
                   'phantomjs.binary.path': './node_modules/karma-phantomjs-launcher/node_modules/phantomjs/bin/phantomjs'
                }
            };
            break;
        default:
            throw 'invalid protractor profile: ' + profile;
    }

    var config = {
      allScriptsTimeout: 11000,

      specs: [
        'e2e/*.js'
      ],

      baseUrl: 'http://localhost:9000/',

      framework: 'jasmine',

      jasmineNodeOpts: {
        defaultTimeoutInterval: 30000
      }
    };

    for (var key in extra) {
        config[key] = extra[key];
    }

    return config;
}());

@@ -682,32 +682,608 @@
          break;%0A
+        case 'travis':%0A            // Travis has Firefox installed.  The GUI emulator xvfb%0A            // (X Virtual Framebuffer) needs to be started prior to running%0A            // Protractor.%0A            extra = %7B%0A                capabilities: %7B%0A                    'browserName': 'firefox'%0A                %7D%0A            %7D;%0A            break;%0A        case 'travis-phantom':%0A            // Travis has phantomjs on the PATH.%0A            extra = %7B%0A                capabilities: %7B%0A                    'browserName': 'firefox'%0A                %7D%0A            %7D;%0A            break;%0A
         default:

Add Travis protractor profiles.