Test for collection frequency code.

This is the test to check if the get_collection_freq() function of the weight api works or not.