This straight up fixes #31 , at least for all my use cases.
We already get the options from mocha, whichever way people may be calling it programmatically. We don't work (well, it falls back to defaults) unless that options hash already contains a key pointing to a file to load its values from... so why not just use that as the entire reporter options config object, instead of having to require it from another file?
Coverage decreased (-3.7%) to 89.024% when pulling 8f8885c3c08720f997eb12bd97bb8449d8758228 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 8f8885c3c08720f997eb12bd97bb8449d8758228 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 8f8885c3c08720f997eb12bd97bb8449d8758228 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 2b6f802384219ff54ab5b21325ff6727092ea2ca on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 3d5f2f019cd1305e9c573fdd7e3501f1f812f6f1 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 3d5f2f019cd1305e9c573fdd7e3501f1f812f6f1 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 3d5f2f019cd1305e9c573fdd7e3501f1f812f6f1 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
Coverage decreased (-3.7%) to 89.024% when pulling 3d5f2f019cd1305e9c573fdd7e3501f1f812f6f1 on gjw:B31-set-config-inline into 7d1ef64cb1631a88d130ae6e664879641f3df50b on stanleyhlng:master.
This straight up fixes #31 , at least for all my use cases.
We already get the options from mocha, whichever way people may be calling it programmatically. We don't work (well, it falls back to defaults) unless that options hash already contains a key pointing to a file to load its values from... so why not just use that as the entire reporter options config object, instead of having to require it from another file?