fix test to generate a correct range of random ints
Merge pull request #480 from michaelplaing/fix-test_next_channel_number_returns_lowest_unused

fix test to generate a correct range of random ints