►
Description
Result: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/28807
Some highlights:
8:10 - We update our global afterEach from runAllTimers to runOnlyPendingTimers
11:54 - We talk about Paul's personal preference against mocking
14:50 - Eipi joins and we summarize the problem
25:30 - We mock debounce for the spec
26:15 - Product placement by Ikea
26:35 - Eipi solves the problem
A
A
B
A
B
So
it
looks
like
the
this
spec
is
whenever
it
does
flake
out
its
flaking
because
run
Alzheimer's,
this
run.
Alzheimer's
will
just
keep
running
as
long
as
it
finds
timers
on
it.
So
it
runs
all
the
timers
that
we've
said
and
then
after
it
runs
those
it
sees.
Do
we
have
more
to
set
running
for
things
like
a
DES,
bouncer
or
a
polar
it
can
cause
these
kind
of
issues
if
you're,
not
careful
so
just
has
another
cool
function
called
run
only
pending
timers.
A
B
B
A
B
B
A
C
A
A
B
D
B
A
A
B
A
B
We
should
probably
fix
that
too
anyways
yeah.
So
it's
like
working
for
me.
Do
you
wanna
share
your
screen.
A
B
A
B
A
A
B
D
A
B
A
B
B
B
A
B
A
D
B
I'm
curious
yeah,
so
you're
talking
about
marking
the
balance.
That
makes
a
lot
of
sense
cuz.
We
don't
need
to
test
the
balance,
wait.
B
A
B
Other
now,
the
way
of
looking
at
it
is
well
it's
part
of
the
components
contract
that,
when
the
input
changes
like
the
balance,
is
more
of
an
implementation
detail
like
we
could
look,
we
could
consider
the
fact
that
there's
this
delay
as
part
of
the
components
contract
I
would
like
I,
don't
I
have
a
personal
preference
against
marking
things
as
much
as
possible.
I
only
do
it
if
we
absolutely
act.
Okay,.
B
A
B
A
A
B
B
So
I
highly
it
as
this
is
a
personal
preference,
because
I
think
people
fall
into
different
camps
of
it
meow
somebody
I
have
I
think
that
I've
seen
a
lot
of
tests
where
we've
mocked
so
much
that.
A
B
No
longer
testing
anything,
that's
actually
gonna,
look
real,
okay
and
so
I
get
nervous
when
we
do
mock
art
and
I,
like
I
like
using
this
phrase
of
collaborators
I
like
try
to
use
real
collaborators
as
much
as
possible
when
things
across
like
some
sort
of
architectural
boundary
like
we're
talking
to
the
back
end,
I'm
doing
really
heavy
native
dawn
thing.
Yeah,
that's
worth
marking
it
for
sure.
But
then
everything
inside
of
me
like,
let's
try
to
keep
it
as
real
as
possible
and
yeah,
rather
than
mocking
it
out
and
just
say,
hey
did.
B
B
I
feel
like
when
you
keep
real
collaborators
having
those
issues
come
up
as
helpful,
but
oh
there's
a
downside
because
it
could
take
a
little
bit
more
time
because
for
some,
especially
there's
some,
you
know
sluggish
part
of
your
code
that
you
want
to
collaborate
with
like
hey,
do
I
use
a
real
store
or
a
mock
store,
and
there
could
be
a
little
bit
of
extra
time
that
takes
to
build
a
real
story.
Yeah.
A
B
B
B
A
C
C
A
We
just
changed
this.
We
had
up
so
we're
getting
the
spec
failure.
Is
you
know
the
timers
are
going
crazy,
basically
run
million
timers.
We
change
the
setup
to
run
only
pending
timers
the
general
setup
and
then
here
we're
just
trying
to
get
it
to
pass
now
with
anything
cuz.
If
we
put
run
opening
timers
and
this
failure,
you
see
on
the
right
happens,
it
again
goes
for
the
run,
a
thousand
timers,
and
then
we
tried
other
stuff.
We
tried
advanced
timers
by
time,
didn't
work.
C
A
A
C
B
I'm
looking
at
researching
this
issue
of
ronald
timers
with
low
bounce
and
it
looks
like
low,
is
to
bounce,
isn't
necessarily
a
trivial
implementation
so
like
they
have
a
lot.
Those
things
they've
put
into
consideration
means
that,
for
these
fake
timers,
it's
not
gonna
play
nicely.
So
I
think
it
could
be
marketed,
balanced,
I
think
that's
what
we
gotta
do.
Yeah,
that's
a
good
call.
B
If
we
mock
it
it
so
here's
here's!
The
interesting
thing
is:
what
how
should
we
mock
we
could
we
could
so
thanks
again
Seder,
we
could
try
it.
We
could
go
ahead,
just
mock
it
for
everybody.
Let's,
maybe
just
do
it
just
to
this
back.
If
we
feel
like
things
more
things
are
coming
out,
do
what
do
you
think
I?
Do
you
think
we
should
market
for
everybody
to.
C
A
C
B
We
were
Lauren
I,
just
had
this
conversation
and
I
was
dropping
my
personal
preference
to
not
mocking
thanks
and
now
IPS
is
representing
the
other,
but
I
agree.
I
think
this
is
falls
in
the
category
of
things
that
are
hard
to
test,
and
so,
if
we
do
set
up
a
mock,
we
could
even
do
something
interesting
where
we
kind
of
set
up
a
fake
and
where,
rather
than
just
saying,
hey
did
we
call
this.
B
We
could
even
then
manually
say,
like
Oh,
run
to
bounce
tick
or
whatever
and
like
we
didn't
quite
still
end
up
testing
it.
If
we
have
either
way
we're
gonna
need
to
replace
the
real
implementation
for
sure,
let's
go
ahead
and
do
it
globally
for
everybody,
it's
probably
a
good
idea
to,
but
if
we
do
a
globally
for
everybody,
we
might
have
some
like
manual
fixes
that
are
gonna
be
not
necessary
anymore.
We
are
we
cool
with
that
yeah.
B
A
B
A
C
C
B
B
A
A
C
B
A
B
A
C
B
B
Parentheses,
sorry
I
know
you're
totally
good,
so
I
took
not
explaining
a
while,
though,.
A
A
C
A
B
B
I
think
we'll
need
to
give
it
if
we'll
need
to
give
it
a
fake,
because
we
do
need
to
call
the
function
we've
passed
to
it,
so
what
debounce
will
do
is
even
import
it.
This
way,
I
don't
think
this.
Is
this
how
we
end
up
half
for
some
reason.
This
is
how
we
end
up
on
all
of
the
low
stop
good
you
just
low
for
the
reason
it
doesn't
work,
that's
something
I.
C
A
B
So
I
I
feel
think
it's
gonna,
it's
not
gonna
be
called
cuz.
We
need
to.
We
need
to
actually
fake
debounce,
all
our
whenever
we're
called
we
return
a
function
and
we
need
to
then
immediately
call
the
function
that
we
got
returned
with
so
I.
Think
oh
IP
has
a
suggestion.
It's
at
least
what
I've
found
in
other
space.
Okay,
guys
check
that
up.
One.
B
A
It's
early
for
me
now,
you're,
good
man,
I
have
been
you.
B
Lost
yeah.
B
B
A
B
C
A
A
C
A
D
B
Have
we're
not
doing
any
asynchronous
call
it's
cold
right
away,
but
hey
and
I
think
I
wrote.
This
bet.
I
was
clearing
it
because
I
wanted
to
be
certain.
It
was
only
called
after
the
stuff
happened.
So
yes,
that's.
Why
marking
it's
not
gonna
work,
because
I'm
trying
to
I'm
trying
to
assert
that
it's
a
synchronously
call
okay,
so
we
need
to
delete
this
line.
Yes,
cool
that
was
I
would
not
have
caught
that.
Okay.
A
B
B
A
A
C
C
B
C
A
B
C
C
A
A
B
B
A
A
C
C
A
B
And
another
thing,
and
that's
a
good
point:
I
like
having
I
like
having
test
helpers
a
lot
and
I
I,
see
some
I've
seen
some
cool
patterns
where
you
can
expose
things
like
we're,
gonna
use,
fake
tea
belts,
or
we
have
like
all
these
I
could
set
up
each
back
to
use
the
site
needs,
and
this
would
rather
than
do
this
kind
of
manual
mocking
or
it's
very
magical
like
how
this
just
works.
Yeah.
A
B
C
On
the
other
hand,
it's
like
with
all
these
extra
stuff
like
every
time,
you're
mocking
excess.
When
are
you,
then,
when
you
would,
for
example,
never
knocks
excess
right
or
when
won't
you
have
more
pixels
and
you
can
be
I
still
have
to
do
these
setups
and
hideous
things
all
the
time.
I
think
just
should
maybe
do
a
better
job
in
explaining
that
to
you
that
it's
mocks
or
maybe
hard
documentation
should
just
be
better
and
be
like
a.
We
have
a
bunch
of
more
stuff.
Please
look
here.
Yeah.
C
A
B
A
B
Be
nice
oh
I'd,
like
I'd
like
to
get
your
opinion,
cuz,
I
I.
Don't
really
100%
know
what
to
think
about
it.
Ip.
But
if
you
look
at
our
global
test
setup,
we
have
after
each
callback
where
we're
on
Alzheimer's,
and
this
is
a
really
good
thing,
because
our
goal
is,
we
want
a
spec,
that's
gonna.
Come
that's
gonna,
be
flaky.
We
wanted
to
fail
for
that
expect.
We
did
run
all
timers,
which
says
this
recursive
call
of
flushing
out
everything.
A
B
C
B
B
Now
we're
you
instead
I,
don't
see
why
we
need
to
do
this
recursive
flushing
of
thanks,
knowing
that
we
don't
have
a
good
pattern
of
cleaning
those
things
up
and
our
code
base
and
it's
just
gonna,
be
a
recipe
for
flaky
tests.
You
know
I
I
feel
like
the
benefit
of
leaving
run
Alzheimer's.
There
does
not
outweigh
the
cost
of
potential
flakes,
so
my
suggestion
is,
is,
let's
do
run
away
pending
timers,
because
that
was
part
of
the
fit
the
job
failure
that
was
happening.
Yeah.
A
C
C
C
C
B
C
B
C
B
B
C
B
B
C
B
Place
well,
yeah,
but
we
haven't.
We
haven't
they're
like
it's,
not
that
I,
don't
trust
low.
The
balance
is
that
we
want
to
really
make
sure
I'm
passing
the
right
stuff
to
low
yeah
and
that's
the
part
I
think
that
makes
me
a
little
nervous.
This
is
technically
then
I
could
just
say
the
balance
passing
the
function,
but
don't
give
it
time
to
it
and
that
or
default
right
is.
B
C
B
Yeah
and
I
think
I
think
that
might
be
a
good
call
to
is
I.
Think
I
like
that,
if
maybe,
if
we
I,
think
that's
interesting,
I'm
a
little
more
I'm
all
for
mocking
it,
you
know
I
just
want
to
double-check
that
you
guys
aren't
concerned
about
adding
too
much
magic
or
that
we're
losing
some
test
coverage
kind
of
thinking.
C
Go
ahead,
yeah
I,
don't
know
to
be
honest,
like
also
often
you
could
even
make
the
argument
that
you
should
stop
out
like
the
debounce
function
right,
because
you
are
actually
not
interested
in
that
the
debounce
function
is
necessarily
called
the
resulting
function.
Escort
you
probably
happy
enough.
Maybe
I
don't
okay,.
B
C
C
A
B
A
B
I
think
we
could
make
our
debounce
I
like
having
smarter
fakes.
I
think
we
could
make
it
a
little,
smarter
and
and
I
might
make
a
really
small
follow-up
issue
on
on
that,
but
yeah
it's
not
right.
Now,
I,
don't
see
it
I
think
we're
gonna
get
a
profitable
decision,
so
I
forget
about
it.
Sorry,
I
get
I,
get
paranoid
about
everything.
So
it's
okay,
sometimes.
A
C
A
C
A
C
B
Thanks
and
gives
you
also
when
we
do
merge
this
in,
would
you
be
able
to
announce
just
our
new
setup
of
this
is
mocks
now
yeah,
awesome!
Well,
hey!
This
was
productive.
I
think
we
fixed
the
flaky
speck
and
feel
that
me
as
the
maintainer
on
EMR,
and
we
can
get
it
in
so
awesome
awesome
any
thanks!
Lauren
for
driving
and
I
think
you're
hopping
on.
Thank.