public void TestNestedAggregations()
        {
            var mog =
                this.deserial.Deserialize <MotherOfGodAggregations>(
                    new RestResponse <MotherOfGodAggregations> {
                Content = TestResources.doubleAggregation
            });
            var output     = new Dictionary <string, Dictionary <string, double> >();
            var fieldNames = new Dictionary <string, string>();

            AggregationHelper.ProcessAggregations(mog.aggregations, 0, ref output, string.Empty, false, ref fieldNames);

            bool success = false;

            foreach (var item in output.Keys)
            {
                if (output[item].Keys.Any(subItem => subItem == "HGIS"))
                {
                    success = true;
                }

                if (success)
                {
                    break;
                }
            }

            Assert.IsTrue(success);
        }
        public void TestSingleValueAggregation()
        {
            var mog = this.deserial.Deserialize <MotherOfGodAggregations>(
                new RestResponse <MotherOfGodAggregations> {
                Content = TestResources.sentimentAggregation
            });
            var output     = new Dictionary <string, Dictionary <string, double> >();
            var fieldNames = new Dictionary <string, string>();

            AggregationHelper.ProcessAggregations(mog.aggregations, 0, ref output, string.Empty, false, ref fieldNames);
        }