chromium/chrome/test/data/extensions/platform_apps/app_view/host_app/background.js

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

chrome.app.runtime.onLaunched.addListener(function() {
  chrome.app.window.create('window.html', {}, function() {
    console.log('Host App is running.');
    chrome.test.sendMessage('AppViewTest.LAUNCHED');
  });
});