adding unit tests for pie chart