On this commit we're adding a new qualifier to the define_enum_for matcher called with_default. This qualifier is used to test that the enum is defined with a default value. A proc can also be passed, and will be called once each time a new value is needed.
It's nice to note that using Time or Date as the return of Procs as default value can lead to flaky tests, so it's recommended to freeze time or date to avoid this.
On this commit we're adding a new qualifier to the
define_enum_for
matcher calledwith_default
. This qualifier is used to test that the enum is defined with a default value. A proc can also be passed, and will be called once each time a new value is needed.It's nice to note that using Time or Date as the return of Procs as default value can lead to flaky tests, so it's recommended to freeze time or date to avoid this.