Increased test coverage on pkg/units

Increased coverage:

  * Added cases to size_test.go
  * Added coverage for duration.go
Using 'case' instead of trickled ifs

Seems the perfect case for case ;).
standardized supported sizes
Compated var declaration and initialization

No need to have two lines. The type is even explicit when we are type
casting to `float32(size)`
Refactor regexp.Compile to init

It would be better to not recompile a static regular expression each
time the function executes. Abstracting it to the `init()` method.

TODO: Check if `panic()` is the right thing to do on `init()`
Moved 'units' catalog out of function

No need to initialize every time the function executes
Remove named returns since not used in func body

Might prevent potential subtle bugs
Better not use `error` as var name

Better not to use `error` as var name since it might eclipse the error
type and cause subtle bugs