Added getPackages() function to nodepackagekit add-on.

The getPackages() function takes a filter as input and returns a
list of packages that match that filter.  For example, the filter
'~installed', results in a list of all the packages not installed
but available.

- added getPackages() to nodepackagekit.cc.
- modified internal handleFiltersArgument() to take an index arg.
- added unit test for getPackages().
- modified the updatePackage() unit test.
- generally cleaned up unit tests.