Fixes indexes of command results.
Uses open() instead of file().
Fixes date test. Adds redhat-packages tests for new fields.