(PUP-1106) Unschedule refreshes on skipped resources

If a given resource is being skipped (e.g. has failed dependencies, is
unscheduled, untagged, etc) that resource should not trigger any
additional behavior. However a resource could be skipped and still have
events trigger behavior. This commit changes the event processing logic
to only process events for resources that should be applied and dequeues
events on resources that should not be applied.
(maint) Use correct data type when unscheduling events

Commit 9d59f204 added the ability to dequeue events on a given resource,
but it did so by setting the value of the target callbacks to an empty
hash. However the value of target callbacks is an array, so if events
were re-queued for a given resource we would get an error like so:

    {}.concat(%w{one two three})
    NoMethodError: undefined method `concat' for {}:Hash

Currently we can't requeue events after dequeuing events, but if this
changes then this code is very incorrect.

This commit fixes the event reset to behave as expected.
Merge pull request #3090 from adrienthebo/issue/master/pup-1106-check-for-failed-deps-on-refresh

(PUP-1106) Check for failed deps on refresh