| Index: chrome/test/data/webui/settings/site_data_test.js
|
| diff --git a/chrome/test/data/webui/settings/site_data_test.js b/chrome/test/data/webui/settings/site_data_test.js
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..bc6d9599a50b171a48da9588210f1e6358a43bd1
|
| --- /dev/null
|
| +++ b/chrome/test/data/webui/settings/site_data_test.js
|
| @@ -0,0 +1,29 @@
|
| +// Copyright 2017 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +suite('<site-data>', function() {
|
| + /** @type {SiteDataElement} */
|
| + var siteData;
|
| +
|
| + /** @type {TestSiteSettingsPrefsBrowserProxy} */
|
| + var testBrowserProxy;
|
| +
|
| + setup(function() {
|
| + testBrowserProxy = new TestSiteSettingsPrefsBrowserProxy;
|
| + settings.SiteSettingsPrefsBrowserProxyImpl.instance_ = testBrowserProxy;
|
| + siteData = document.createElement('site-data');
|
| + });
|
| +
|
| + test('tapping remove button (trash can) calls remove on origin', function() {
|
| + var GOOGLE_ID = '1';
|
| + siteData.sites = [{site: 'Google', id: GOOGLE_ID, localData: 'Cookiez!'}];
|
| + Polymer.dom.flush();
|
| +
|
| + MockInteractions.tap(siteData.$$('.remove-site'));
|
| +
|
| + return testBrowserProxy.whenCalled('removeCookie').then(function(path) {
|
| + assertEquals(GOOGLE_ID, path);
|
| + });
|
| + });
|
| +});
|
|
|