gpii-universal
Version:
Cross platform, core components of the GPII personalization infrastructure.
255 lines (191 loc) • 5.51 kB
Plain Text
#
# write-test.ini: An ini file to test writing
# write-test.expect.ini: The expected output of a modifying write-test.ini
#
# Keys and sections begining with "remove_" will be removed.
# Keys begining with "ml_" will have multi-line values added.
# normal key=value
key=abc key xyz
key2=abc key2 xyz
100=abc 100 xyz
# set an empty value
empty=abc empty xyz
# some changes
empty_me=
null_me=
number_me1=42
number_me2="12345"
true_me1=true
true_me2="true"
# removal
keep1=abc keep1 xyz
keep2=abc keep2 xyz
# Spaces (surrounding space should be kept)
spaced = abc spaced xyz
spacedL =abc spacedL xyz
spacedR= abc spacedR xyz
# Spaces in values and around delimiter
notspaced = abc notspaced xyz
spaced2 = abc spaced2 xyz
spaced left =abc spaced left xyz
spaced right= abc spaced right xyz
spaced none=abc spaced none xyz
double space = abc double space xyz
double space and value = abc double space and value xyz
# Colons as delimiters
colon1:abc colon1 xyz
colon2 : abc colon2 xyz
colon3 : abc colon3 xyz
colon+equal:abc colon+equal xyz
equal+colon=abc equal+colon xyz
# Quoted values
quoted_ns="abc quoted_ns xyz"
quoted_spc = "abc quoted_spc xyz"
quoted_spcL ="abc quoted_spcL xyz"
quoted_spcR= "abc quoted_spcR xyz"
quoted_spc_value = "abc quoted_spc_value xyz"
quoted_spc_valueL = "abc quoted_spc_valueL xyz"
quoted_spc_valueR = "abc quoted_spc_valueR xyz"
quoted_spc_valueB = "abc quoted_spc_valueB xyz"
quote"in"key = abc quote"in"key xyz
quote"in"key2 = "abc quote"in"key2 xyz"
quotes_only="abc quotes_only xyz"
# Single quotes
single_quote='abc single_quote xyz'
single_quote_spc = 'abc single_quote_spc xyz'
single_quote_only='abc single_quote_only xyz'
# Multi-line values, with triple quote
ml_1line="""abc ml_1line xyz line0"""
ml_2line="""abc ml_2line xyz line0
abc ml_2line xyz line1"""
ml_3line="""abc ml_3line xyz line0
abc ml_3line xyz line1
abc ml_3line xyz line2"""
triple_quote_empty1="""abc triple_quote_empty1 xyz"""
# Triple single-quote
ml_single_quote='''abc ml_single_quote xyz line0
abc ml_single_quote xyz line1
abc ml_single_quote xyz line2'''
# New-lines via indentation
ml_indent=abc ml_indent xyz line0
abc ml_indent xyz line1
abc ml_indent xyz line2
ml_indent_comment=abc ml_indent_comment xyz line0
abc ml_indent_comment xyz line1
abc ml_indent_comment xyz line2
# comment not part of the value.
ml_indent_kv=abc ml_indent_kv xyz line0
abc ml_indent_kv xyz line1
abc ml_indent_kv xyz line2
ml_indent_kv_after=abc ml_indent_kv_after xyz line0
abc ml_indent_kv_after xyz line1
abc ml_indent_kv_after xyz line2
not_ml_indent_kv_after=abc not_ml_indent_kv_after xyz
ml_indent_deep=abc ml_indent_deep xyz line0
abc ml_indent_deep xyz line1
abc ml_indent_deep xyz line2
ml_indent_deep_after=abc ml_indent_deep_after xyz line0
abc ml_indent_deep_after xyz line1
abc ml_indent_deep_after xyz line2
not_ml_indent_deep_after=abc not_ml_indent_deep_after xyz
# Different values with the same key can exist in different sections
sectionX=abc sectionX xyz
new_empty=
new_null=
new_number=42
new_true=true
newKey1=new value
[section1]
section1_key1=abc section1_key1 xyz
section1_key2=abc section1_key2 xyz
sectionX=abc sectionX xyz
newKey1=new value 1, in section1
newKey2=new value 2
[section2]
section2_key1=abc section2_key1 xyz
sectionX=abc sectionX xyz
[[subsection2A]]
subsection2A=abc subsection2A xyz
sectionX=abc sectionX xyz
[[subsection2B]]
subsection2B=abc subsection2B xyz
sectionX=abc sectionX xyz
[section3]
section3_key=abc section3_key xyz
sectionX=abc sectionX xyz
[[subsection3]]
subsection3_key=abc subsection3_key xyz
sectionX=abc sectionX xyz
[[[subsubsection3]]]
subsubsection3_key=abc subsubsection3_key xyz
sectionX=abc sectionX xyz
[[[[subsubsubsection3]]]]
subsubsubsection3_key=abc subsubsubsection3_key xyz
sectionX=abc sectionX xyz
[[[subsubsection3B]]]
subsubsubsection3B_key=abc subsubsubsection3B_key xyz
sectionX=abc sectionX xyz
[section4]
section4=abc section4 xyz
sectionX=abc sectionX xyz
[[indented]]
key=abc key xyz
[[notindented]]
key=abc key xyz
[empty_section]
[empty_section_no_space_below]
[empty_section_no_space_between]
[empty_section_no_space_above]
[empty_with_sub]
[[empty_sub]]
[section_no_space]
key=abc key xyz
[section_no_space2]
key=abc key xyz
[section_space]
key=abc key xyz
[section.with.dot]
key=abc key xyz
keyA=abc keyA xyz
[section]
[[with.dot]]
key=abc key xyz
keyB=abc keyB xyz
[section onespace]
key=abc key xyz
keyA=abc keyA xyz
[section two space]
key=abc key xyz
keyB=abc keyB xyz
# Sub-section can have the same name as the container.
[sub_section_same]
key1=abc key1 xyz
keyA=abc keyA xyz
[[sub_section_same]]
key1=abc key1 xyz
keyB=abc keyB xyz
# Remove sections - the section header doesn't get removed, but the contents do.
[section_remain1]
key_should_remain1=abc key_should_remain1 xyz
[remove_section1]
[section_remain2]
key_should_remain1=abc key_should_remain1 xyz
[remove_section2]
[[subsection_should_empty2]]
[[[subsubsection_should_empy22]]]
[section_keep]
key_should_remain=abc key_should_remain xyz
[[remove_section3]]
[[section_remains]]
key_should_remain=abc key_should_remain xyz
[final_section]
complete=abc complete xyz
[newSection1]
newKey1=new value 1, in new section 1
newKey3=new value 3
[newSection2]
newKey1=new value 1, in new section 2
newKey4=new value 4
[[newSubSection]]
newKey1=new value 1, in new sub section
newKey5=new value 5