 
 
   MapTest(const int hash_table_size = 100)
-    : the_map(hash_table_size), size(hash_table_size)
+    : size(hash_table_size), the_map(new map_type(hash_table_size))
   {
-
-
   }
 
   ~MapTest(){


  auto max = [](value_type a, value_type b) { return (a >= b ? a : b); };

  this->the_map.insert(first_pair, max);
  auto found = this->the_map.find(0);
  EXPECT_EQ(0, found->second);

  this->the_map.insert(second_pair, max);
  found = this->the_map.find(0);
  EXPECT_EQ(10, found->second);

  this->the_map.insert(third_pair, max);
  found = this->the_map.find(0);
  EXPECT_EQ(10, found->second);

  this->the_map.insert(thrust::make_pair(0,11), max);
  found = this->the_map.find(0);
  EXPECT_EQ(11, found->second);


  this->the_map.insert(thrust::make_pair(7, 42), max);
  found = this->the_map.find(7);
  EXPECT_EQ(42, found->second);

  this->the_map.insert(thrust::make_pair(7, 62), max);
  found = this->the_map.find(7);
  EXPECT_EQ(62, found->second);

  this->the_map.insert(thrust::make_pair(7, 42), max);
  found = this->the_map.find(7);
  EXPECT_EQ(62, found->second);

  found = this->the_map.find(0);
  EXPECT_EQ(11, found->second);

}

  using key_type = typename TypeParam::key_type;
  using value_type = typename TypeParam::value_type;

  auto begin = this->the_map->begin();
  auto end = this->the_map->end();
  EXPECT_NE(begin,end);

}

TYPED_TEST(MapTest, CheckUnusedValues){

  EXPECT_EQ(this->the_map->get_unused_key(), this->unused_key);

  auto begin = this->the_map->begin();
  EXPECT_EQ(begin->first, this->unused_key);
  EXPECT_EQ(begin->second, this->unused_value);
}
