Fix for needs() incorrect behavior

Moved the check to see if needs are met until after the command line flags are
processed so the check can see if an option is both defined and passed in by the
user. Added unit tests to cover fix as well.
Merge pull request #36 from omnicolor/dev

Fix for needs() incorrect behavior