Implemented card dealing function & tried out a test for it.