Set field types and serialize as koral:fields
Change-Id: I6f256fcbf3996e6ae45db60bc3aef98ff431b0b9
diff --git a/t/sgbr/meta.t b/t/sgbr/meta.t
index 20b5ad8..aa0fc10 100644
--- a/t/sgbr/meta.t
+++ b/t/sgbr/meta.t
@@ -26,46 +26,46 @@
my $meta = $doc->meta;
-is($meta->{title}, 'Sommerüberraschung', 'title');
-is($meta->{author}, 'TEST.BSP.Autoren.1', 'Author');
-is($meta->{'sgbr_author_age_class'}, 'X', 'AgeClass');
+is($meta->{T_title}, 'Sommerüberraschung', 'title');
+is($meta->{T_author}, 'TEST.BSP.Autoren.1', 'Author');
+is($meta->{'S_sgbr_author_age_class'}, 'X', 'AgeClass');
-is($meta->{'sgbr_author_sex'}, 'M', 'Sex');
-is($meta->{'sgbr_kodex'}, 'M', 'Kodex');
+is($meta->{'S_sgbr_author_sex'}, 'M', 'Sex');
+is($meta->{'S_sgbr_kodex'}, 'M', 'Kodex');
-is($meta->{doc_title}, 'Beispielkorpus', 'Doc: title');
-is($meta->{doc_sub_title}, 'Subkorpus Beispieltext', 'Doc: subtitle');
+is($meta->{T_doc_title}, 'Beispielkorpus', 'Doc: title');
+is($meta->{T_doc_sub_title}, 'Subkorpus Beispieltext', 'Doc: subtitle');
-is($meta->{language}, 'de', 'Language');
+is($meta->{S_language}, 'de', 'Language');
-ok(!$meta->{publisher}, 'Publisher');
-ok(!$meta->{editor}, 'Editor');
-ok(!$meta->{text_type}, 'Text Type');
-ok(!$meta->{text_type_art}, 'Text Type Art');
-ok(!$meta->{text_type_ref}, 'Text Type Ref');
-ok(!$meta->{text_column}, 'Text Column');
-ok(!$meta->{text_domain}, 'Text Domain');
-ok(!$meta->{creation_date}, 'Creation Date');
+ok(!$meta->{A_publisher}, 'Publisher');
+ok(!$meta->{A_editor}, 'Editor');
+ok(!$meta->{S_text_type}, 'Text Type');
+ok(!$meta->{S_text_type_art}, 'Text Type Art');
+ok(!$meta->{S_text_type_ref}, 'Text Type Ref');
+ok(!$meta->{S_text_column}, 'Text Column');
+ok(!$meta->{S_text_domain}, 'Text Domain');
+ok(!$meta->{D_creation_date}, 'Creation Date');
ok(!$meta->{license}, 'License');
ok(!$meta->{pages}, 'Pages');
-ok(!$meta->{file_edition_statement}, 'File Edition Statement');
-ok(!$meta->{bibl_edition_statement}, 'Bibl Edition Statement');
-ok(!$meta->{reference}, 'Reference');
+ok(!$meta->{A_file_edition_statement}, 'File Edition Statement');
+ok(!$meta->{A_bibl_edition_statement}, 'Bibl Edition Statement');
+ok(!$meta->{A_reference}, 'Reference');
-ok(!$meta->{doc_editor}, 'Doc: editor');
-ok(!$meta->{doc_author}, 'Doc: author');
+ok(!$meta->{A_doc_editor}, 'Doc: editor');
+ok(!$meta->{T_doc_author}, 'Doc: author');
-ok(!$meta->{corpus_title}, 'Corpus: title');
-ok(!$meta->{corpus_sub_title}, 'Corpus: subtitle');
-ok(!$meta->{corpus_editor}, 'Corpus: editor');
-ok(!$meta->{corpus_author}, 'Corpus: author');
+ok(!$meta->{T_corpus_title}, 'Corpus: title');
+ok(!$meta->{T_corpus_sub_title}, 'Corpus: subtitle');
+ok(!$meta->{A_corpus_editor}, 'Corpus: editor');
+ok(!$meta->{T_corpus_author}, 'Corpus: author');
my $hash = $doc->to_hash;
is($hash->{title}, 'Sommerüberraschung', 'Corpus title');
is($hash->{sgbrAuthorSex}, 'M', 'additional');
# Sgbr specific keywords
-is($meta->keywords('keywords'), 'sgbrAuthorAgeClass:X sgbrAuthorSex:M sgbrKodex:M');
+is($meta->keywords('K_keywords'), 'sgbrAuthorAgeClass:X sgbrAuthorSex:M sgbrKodex:M');
done_testing;