Commit Graph

24 Commits

Author SHA1 Message Date
Antony Male f7ec7a255a WIP towards getting unit tests working 2019-09-22 17:12:53 +01:00
Antony Male b9d1487e91 Fix access modifier on BootstrapperBase.Launch 2016-02-02 08:24:31 +00:00
Antony Male e0c7edd27a Rework slightly how the root VM is launched, to avoid it being created only to be disposed 2016-01-27 12:30:26 +00:00
Antony Male 5d752f1fa9 Dispose the RootViewModel when Bootstrapper disposed
The Bootstrapper owns the RootViewModel, so this is the right thing
to do
2016-01-08 11:47:37 +00:00
Antony Male fc7f164c53 Remove unnecessary usings in unit tests 2015-09-23 21:46:36 +01:00
Antony Male 97192899eb Eliminate View.ViewManager
I think that's the last step towards supporting multiple Applications
(if anyone every actually wants to do that). It's good architecture,
anyway
2015-06-02 15:51:27 +01:00
Antony Male 386b7cb035 Bring more sanity to the Bootstrapper 2015-02-09 12:39:21 +00:00
Antony Male 07160aa4fe Make BootstrapperBase non-generic
Instead, it has an abstract RootViewModel property, which bootstrapper
overrides to return an instance of TRootViewModel from the container.

This means that the root ViewModel is treated a singleton by the bootstrapper,
regardless of whether it's singleton in the container
2015-01-15 10:06:00 +00:00
Antony Male b538f11453 Fix up previous commit 2015-01-05 12:21:46 +00:00
Antony Male f36de34bb2 Execute.Dispatcher can never be null, and dispatches synchronously by default
The previous behaviour was to raise an exception unless Execute.Dispatcher
had been explicitly defined. This was to detect cases where the user hadn't
set up Execute correctly, and treat them as errors rather than simply going
ahead with some possibly-unexpected behaviour.

However, since BootstrapperBase sets Execute.Dispatcher automatically, it's
highly unlikely that itwould ever not be set when it needed to be. Exceptions
are design mode and unit tests, both of which want (or can cope with) a
synchronous dispatcher.

Hence the behaviour change. Execute.Dispatcher is a synchronous dispatcher
by default, but is overridden to one that uses Application.Current.Dispatcher
by the bootstrapper if we're in a real application.
2015-01-04 21:30:34 +00:00
Antony Male 9ee23f1469 Remove Execute.TestExecuteSynchronously, in favour of a synchronous IDispatcher implementation 2015-01-04 13:10:37 +00:00
Antony Male 2ed54c4acd Refactor BootstrapperBase slightly, to call OnStartup at a better point in time 2015-01-04 12:28:02 +00:00
Antony Male f47db1cbec Change some Bootstrapper methods to public, to avoid explicit interface implementation 2014-12-02 15:20:16 +00:00
Antony Male 743961ec68 ViewManager now accepts an IViewManagerConfig, which makes the IoC container setup neater 2014-12-02 12:52:58 +00:00
Antony Male a421fc6922 Remove AssemblySource, relying instead on a List<Assembly> on BootstrapperBase 2014-11-30 15:19:13 +00:00
Antony Male 0f93eb1832 Remove the IoC class in its entirety - it's not needed any more, and it's a bad idea 2014-11-30 14:23:56 +00:00
Antony Male db08349c02 Add unit tests for ApplicationLoader, and fix Bootstrapper tests 2014-08-02 17:50:18 +01:00
Antony Male b254f92fe8 Add OnStart hook for when Stylet starts up, and rename the existing hooks to avoid confusion 2014-07-23 13:24:12 +01:00
Antony Male 0ba6061e59 Move BootstrapperBase's autoLaunch to Start 2014-05-21 12:22:13 +01:00
Antony Male 99f79d1e29 Add more unit tests for MessageBox, and convert to use more system types 2014-05-20 21:24:29 +01:00
Antony Male 5823437a28 Support design-time application running 2014-05-16 09:46:16 +01:00
Antony Male fc4a7fb61c Push coverage up to 99.7% 2014-05-10 20:11:02 +01:00
Antony Male e4f80348f9 Remove BootstrapperBase tests, as I'm having lots of problems running an Application inside a unit test context 2014-03-12 21:27:10 +00:00
Antony Male aa395d9cb5 Start writing unit tests for BootstrapperBase 2014-03-12 13:10:25 +00:00