If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

events.skip should be removed, i think?

RESOLVED WONTFIX

Status

Testing Graveyard
Mozmill
RESOLVED WONTFIX
7 years ago
a year ago

People

(Reporter: Jeff Hammel, Unassigned)

Tracking

Details

(Whiteboard: [mozmill-2.0+])

(Reporter)

Description

7 years ago
What does events.skip mean?!?

We have an events.skip but...I have no idea when this makes sense.
E.g. can you skip a keypress event? What does this mean in practice?
head asplode

https://github.com/mozautomation/mozmill/blob/master/mozmill/mozmill/extension/resource/modules/frame.js#L241

Currently we use it to skip setupModule and that sort of thing (see
below).  Are we happy with this? Is there any reason we shouldn't just
call the endTest event and skip the whole test?  I don't know!  At
best it should be documented better

See 
https://bugzilla.mozilla.org/show_bug.cgi?id=628277#c5

--->>>
       /home/jhammel/mozmill/src/mozmill/mozmill/mozmill/extension/resource/modules/frame.js
       :
242-  }
243-  events.fireEvent('fail', obj);
244-}
245:events.skip = function (reason) {
246-  events.currentTest.skipped = true;
247-  events.currentTest.skipped_reason = reason;
248-  for each(var timer in timers) {
--
431-  // skip excluded platforms
432-  if (func.EXCLUDED_PLATFORMS != undefined) {
433-    if (arrays.inArray(func.EXCLUDED_PLATFORMS, this.platform)) {
434:      events.skip("Platform exclusion");
435-      return;
436-    }
437-  }
438-
439-  // skip function if requested
440-  if (func.__force_skip__ != undefined) {
441:    events.skip(func.__force_skip__);
442-    return;
443-  }
444-
--
507-            break;
508-        }
509-      } else {
510:        events.skip("setupTest failed.");
511-      }
512-      if (module.__teardownTest__) {
513-        events.setState('teardownTest'); 
--
521-  } else {
522-    for each(var test in module.__tests__) {
523-      events.setTest(test);
524:      events.skip("setupModule failed.");
525-      events.endTest(test);
526-    }
527-  }
(Reporter)

Updated

7 years ago
Whiteboard: [mozmill-2.0?]
Wow, I have never known that we could use frame.skip to skip any function. So not sure if this will be useful anymore when we mark tests to be skipped in manifests only.

Comment 2

7 years ago
If we're not using this we should clean it up but we need to be certain that:
1. skipped tests are counted 
2. tests have a way to skip themselves
Whiteboard: [mozmill-2.0?] → [mozmill-2.0+]

Comment 3

6 years ago
no, we should keep this.  WONTFIX
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → WONTFIX
(Assignee)

Updated

a year ago
Product: Testing → Testing Graveyard
You need to log in before you can comment on or make changes to this bug.