CiscoCloud / distributive

Unit testing for the cloud
Apache License 2.0
147 stars 20 forks source link

A better way to register constructors #17

Closed langston-barrett closed 9 years ago

langston-barrett commented 9 years ago

The dict/switch scenario in main.go is unsustainable. We need something like

registerCheck(name string, thunk Thunk, numParams int)

Every single check will now just take a list of strings, Parameters. They will simply return an exit code and exit message. This is a complete overhaul of the internal architecture, but I've already got a working version (decomposition FTW).

This should ultimately lead to more sustainability and simpler code.