Skip to content

Commit

Permalink
Fix test-amp-form and test-amp-gwd-animation.
Browse files Browse the repository at this point in the history
  • Loading branch information
William Chou committed Dec 12, 2018
1 parent aa7fd25 commit 7e15c81
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion extensions/amp-form/0.1/test/test-amp-form.js
Original file line number Diff line number Diff line change
Expand Up @@ -1443,7 +1443,7 @@ describes.repeated('', {
it('should install action handler and handle submit action', () => {
const form = getForm();
document.body.appendChild(form);
const actions = Services.actionServiceForDoc(env.ampdoc);
const actions = Services.actionServiceForDoc(form);

sandbox.stub(actions, 'installActionHandler');
const ampForm = new AmpForm(form);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ describes.sandboxed('AMP GWD Animation', {}, () => {
element = el;
impl = element.implementation_;
runtime = getExistingServiceForDocInEmbedScope(
variant.ampdoc == 'fie' ? element : ampdoc, GWD_SERVICE_NAME);
element, GWD_SERVICE_NAME);
page1Elem = doc.getElementById('page1');
});
});
Expand Down Expand Up @@ -451,8 +451,7 @@ describes.sandboxed('AMP GWD Animation', {}, () => {
const triggeredAmpEventNames = [];
const triggeredEvents = [];

const actionService = Services.actionServiceForDoc(
variant.ampdoc == 'fie' ? element : ampdoc);
const actionService = Services.actionServiceForDoc(element);
sandbox.stub(actionService, 'trigger').callsFake(
(target, name, event) => {
triggeredAmpEventNames.push(name);
Expand Down

0 comments on commit 7e15c81

Please sign in to comment.