Page MenuHomePhabricator

When running unit tests, ignore any custom task fields
ClosedPublic

Authored by epriestley on Apr 2 2017, 3:49 PM.
Tags
None
Referenced Files
F15381152: D17595.diff
Fri, Mar 14, 6:08 AM
Unknown Object (File)
Feb 21 2025, 3:17 PM
Unknown Object (File)
Feb 20 2025, 9:12 PM
Unknown Object (File)
Feb 15 2025, 11:19 PM
Unknown Object (File)
Feb 15 2025, 7:24 AM
Unknown Object (File)
Feb 10 2025, 3:18 AM
Unknown Object (File)
Feb 9 2025, 3:38 AM
Unknown Object (File)
Feb 9 2025, 3:38 AM
Subscribers
None

Details

Summary

If you have maniphest.custom-field-definitions set to include "required" fields, a bunch of tests which create tasks can fail.

To avoid this, reset this config while running tests.

This mechanism should probably be more general (e.g., reset all config by default, only whitelist some config) but just fix this for now since it's a one-liner and doesn't make eventual cleanup any harder.

Test Plan

Ran arc unit, hitting tests that create tasks.

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

This revision is now accepted and ready to land.Apr 2 2017, 4:13 PM
This revision was automatically updated to reflect the committed changes.