genTestsS :: [String] -> String
genTestsS types = concat $ map ("    "++) $ concat [sizes_lines, aligns_lines, off_lines, fields_lines]
    where fst_line  = "main = hspec $ do\n"
          size  n   = concat ["it \"", n, "\" $ property $ (same_size      :: ", n," -> Expectation)\n"]
          align n   = concat ["it \"", n, "\" $ property $ (same_alignment :: ", n," -> Expectation)\n"]
          off   n   = concat ["it \"", n, "\" $ property $ (same_offsets   :: ", n," -> Expectation)\n"]
          fields n  = concat ["it \"", n, "\" $ property $ (same_fields    :: ", n," -> Expectation)\n"]
          sizes_lines  = ("describe \"Test for same size - sums\" $ do\n" ): (map (\t -> "    " ++ size t) types)
          aligns_lines = ("describe \"Test for same alignment - sums\" $ do\n" ): (map (\t -> "    " ++ align t) types)
          off_lines    = ("describe \"Test for same offsets - sums\" $ do\n" ): (map (\t -> "    " ++ off t) types)
          fields_lines = ("describe \"Test for same fields - sums\" $ do\n" ): (map (\t -> "    " ++ fields t) types)

-- -------
-- -------
-- 
genTestsS :: [String] -> String
genTestsS types = concat $ map ("    "++) $ concat [sizes_lines, aligns_lines, off_lines, fields_lines]
    where fst_line  = "main = hspec $ do\n"
          size  n   = concat ["it \"", n, "\" $ property $ (same_size      :: ", n," -> Expectation)\n"]
          align n   = concat ["it \"", n, "\" $ property $ (same_alignment :: ", n," -> Expectation)\n"]
          off   n   = concat ["it \"", n, "\" $ property $ (same_offsets   :: ", n," -> Expectation)\n"]
          fields n  = concat ["it \"", n, "\" $ property $ (same_fields    :: ", n," -> Expectation)\n"]
          sizes_lines  = ("describe \"Test for same size - sums\" $ do\n" ): (map (\t -> "    " ++ size t) types)
          aligns_lines = ("describe \"Test for same alignment - sums\" $ do\n" ): (map (\t -> "    " ++ align t) types)
          off_lines    = ("describe \"Test for same offsets - sums\" $ do\n" ): (map (\t -> "    " ++ off t) types)
          fields_lines = ("describe \"Test for same fields - sums\" $ do\n" ): (map (\t -> "    " ++ fields t) types)

-- -------
-- -------
-- 
genTestsS types = concat $ map ("    "++) $ concat [sizes_lines, aligns_lines, off_lines, fields_lines]
    where fst_line  = "main = hspec $ do\n"
          size  n   = concat ["it \"", n, "\" $ property $ (same_size      :: ", n," -> Expectation)\n"]
          align n   = concat ["it \"", n, "\" $ property $ (same_alignment :: ", n," -> Expectation)\n"]
          off   n   = concat ["it \"", n, "\" $ property $ (same_offsets   :: ", n," -> Expectation)\n"]
          fields n  = concat ["it \"", n, "\" $ property $ (same_fields    :: ", n," -> Expectation)\n"]
          sizes_lines  = ("describe \"Test for same size - sums\" $ do\n" ): (map (\t -> "    " ++ size t) types)
          aligns_lines = ("describe \"Test for same alignment - sums\" $ do\n" ): (map (\t -> "    " ++ align t) types)
          off_lines    = ("describe \"Test for same offsets - sums\" $ do\n" ): (map (\t -> "    " ++ off t) types)
          fields_lines = ("describe \"Test for same fields - sums\" $ do\n" ): (map (\t -> "    " ++ fields t) types)

-- -------
-- -------
-- 