Dub: Introduce a class to use in unittests
Currently, unit tests for dub fails on my machine
as I have a custom registry configured. This is a great
example as to why unittests shouldn't do IO or depend on the
environment, as they can randomly fail. The new TestDub class,
private to dub-application at the moment, is a band-aid for this.
I am hoping that over time, we can perform more dependency injection
with the same method as used here (or by providing a class that encloses
all IO) so that we do not need to subclass Dub.
1 parent 0780082 commit 293fd42026ff9eb93b6f3b9bec860b55d60a5415
@Geod24 Geod24 authored on 24 Aug 2022
Mathias LANG committed on 24 Aug 2022
Showing 1 changed file
View
source/dub/dub.d