From 5dd69d2ce2896e6274f04d0b8f8156da6a890264 Mon Sep 17 00:00:00 2001 From: Michael Bideau Date: Sun, 1 Nov 2020 13:21:17 +0100 Subject: [PATCH] Test: added two tests cases for merging on specific attributes --- .../expected/Mr Forrest Gump.vcard | 19 +++++++++++++++++++ .../Merging by default attributes/options | 1 + .../src/Forrest_Gump.v2.1.vcf | 18 ++++++++++++++++++ .../src/Forrest_Gump.v3.0.vcf | 16 ++++++++++++++++ .../expected/Mr Forrest Gump.vcard | 19 +++++++++++++++++++ .../Merging by single attributes/options | 1 + .../src/Forrest_Gump.v2.1.vcf | 18 ++++++++++++++++++ .../src/Forrest_Gump.v3.0.vcf | 16 ++++++++++++++++ 8 files changed, 108 insertions(+) create mode 100644 test/cases/Merging by default attributes/expected/Mr Forrest Gump.vcard create mode 100644 test/cases/Merging by default attributes/options create mode 100644 test/cases/Merging by default attributes/src/Forrest_Gump.v2.1.vcf create mode 100644 test/cases/Merging by default attributes/src/Forrest_Gump.v3.0.vcf create mode 100644 test/cases/Merging by single attributes/expected/Mr Forrest Gump.vcard create mode 100644 test/cases/Merging by single attributes/options create mode 100644 test/cases/Merging by single attributes/src/Forrest_Gump.v2.1.vcf create mode 100644 test/cases/Merging by single attributes/src/Forrest_Gump.v3.0.vcf diff --git a/test/cases/Merging by default attributes/expected/Mr Forrest Gump.vcard b/test/cases/Merging by default attributes/expected/Mr Forrest Gump.vcard new file mode 100644 index 0000000..5686e7b --- /dev/null +++ b/test/cases/Merging by default attributes/expected/Mr Forrest Gump.vcard @@ -0,0 +1,19 @@ +BEGIN:VCARD +VERSION:3.0 +ADR;TYPE=WORK,PREF:;;100 Waters Edge;Baytown;LA;30314;United States of Amer + ica +ADR;TYPE=HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +EMAIL:forrestgump@example.com +FN:Mr Forrest Gump +LABEL;CHARSET=UTF-8;TYPE=WORK,PREF:100 Waters Edge\nBaytown\, LA 30314\nUni + ted States of America +LABEL;CHARSET=UTF-8;TYPE=HOME:42 Plantation St.\nBaytown\, LA 30314\nUnited + States of America +N:Gump;Mr Forrest;;; +ORG:Bubba Gump Shrimp Co. +PHOTO;TYPE=GIF;VALUE=URI:http://www.example.com/dir_photos/my_photo.gif +REV:2008-04-24T19:52:43Z +TEL;TYPE=WORK,VOICE:(111)555-1212 +TEL;TYPE=HOME,VOICE:(404)555-1212 +TITLE:Shrimp Man +END:VCARD diff --git a/test/cases/Merging by default attributes/options b/test/cases/Merging by default attributes/options new file mode 100644 index 0000000..ed8b9ec --- /dev/null +++ b/test/cases/Merging by default attributes/options @@ -0,0 +1 @@ +--merge diff --git a/test/cases/Merging by default attributes/src/Forrest_Gump.v2.1.vcf b/test/cases/Merging by default attributes/src/Forrest_Gump.v2.1.vcf new file mode 100644 index 0000000..cbda370 --- /dev/null +++ b/test/cases/Merging by default attributes/src/Forrest_Gump.v2.1.vcf @@ -0,0 +1,18 @@ +BEGIN:VCARD +VERSION:2.1 +N:Gump;Forrest;;Mr. +FN:Forrest Gump +ORG:Bubba Gump Shrimp Co. +TITLE:Shrimp Man +PHOTO;GIF:http://www.example.com/dir_photos/my_photo.gif +TEL;WORK;VOICE:(111) 555-1212 +TEL;HOME;VOICE:(404) 555-1212 +ADR;WORK;PREF:;;100 Waters Edge;Baytown;LA;30314;United States of America +LABEL;WORK;PREF;ENCODING=QUOTED-PRINTABLE;CHARSET=UTF-8:100 Waters Edge=0D= + =0ABaytown\, LA 30314=0D=0AUnited States of America +ADR;HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +LABEL;HOME;ENCODING=QUOTED-PRINTABLE;CHARSET=UTF-8:42 Plantation St.=0D=0A= + Baytown, LA 30314=0D=0AUnited States of America +EMAIL:forrestgump@example.com +REV:20080424T195243Z +END:VCARD diff --git a/test/cases/Merging by default attributes/src/Forrest_Gump.v3.0.vcf b/test/cases/Merging by default attributes/src/Forrest_Gump.v3.0.vcf new file mode 100644 index 0000000..e0b18cd --- /dev/null +++ b/test/cases/Merging by default attributes/src/Forrest_Gump.v3.0.vcf @@ -0,0 +1,16 @@ +BEGIN:VCARD +VERSION:3.0 +N:Gump;Forrest;;Mr.; +FN:Forrest Gump +ORG:Bubba Gump Shrimp Co. +TITLE:Shrimp Man +PHOTO;VALUE=URI;TYPE=GIF:http://www.example.com/dir_photos/my_photo.gif +TEL;TYPE=WORK,VOICE:(111) 555-1212 +TEL;TYPE=HOME,VOICE:(404) 555-1212 +ADR;TYPE=WORK,PREF:;;100 Waters Edge;Baytown;LA;30314;United States of America +LABEL;TYPE=WORK,PREF:100 Waters Edge\nBaytown\, LA 30314\nUnited States of America +ADR;TYPE=HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +LABEL;TYPE=HOME:42 Plantation St.\nBaytown\, LA 30314\nUnited States of America +EMAIL:forrestgump@example.com +REV:2008-04-24T19:52:43Z +END:VCARD diff --git a/test/cases/Merging by single attributes/expected/Mr Forrest Gump.vcard b/test/cases/Merging by single attributes/expected/Mr Forrest Gump.vcard new file mode 100644 index 0000000..5686e7b --- /dev/null +++ b/test/cases/Merging by single attributes/expected/Mr Forrest Gump.vcard @@ -0,0 +1,19 @@ +BEGIN:VCARD +VERSION:3.0 +ADR;TYPE=WORK,PREF:;;100 Waters Edge;Baytown;LA;30314;United States of Amer + ica +ADR;TYPE=HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +EMAIL:forrestgump@example.com +FN:Mr Forrest Gump +LABEL;CHARSET=UTF-8;TYPE=WORK,PREF:100 Waters Edge\nBaytown\, LA 30314\nUni + ted States of America +LABEL;CHARSET=UTF-8;TYPE=HOME:42 Plantation St.\nBaytown\, LA 30314\nUnited + States of America +N:Gump;Mr Forrest;;; +ORG:Bubba Gump Shrimp Co. +PHOTO;TYPE=GIF;VALUE=URI:http://www.example.com/dir_photos/my_photo.gif +REV:2008-04-24T19:52:43Z +TEL;TYPE=WORK,VOICE:(111)555-1212 +TEL;TYPE=HOME,VOICE:(404)555-1212 +TITLE:Shrimp Man +END:VCARD diff --git a/test/cases/Merging by single attributes/options b/test/cases/Merging by single attributes/options new file mode 100644 index 0000000..5a2b4af --- /dev/null +++ b/test/cases/Merging by single attributes/options @@ -0,0 +1 @@ +--merge -a email --no-match-approx diff --git a/test/cases/Merging by single attributes/src/Forrest_Gump.v2.1.vcf b/test/cases/Merging by single attributes/src/Forrest_Gump.v2.1.vcf new file mode 100644 index 0000000..cbda370 --- /dev/null +++ b/test/cases/Merging by single attributes/src/Forrest_Gump.v2.1.vcf @@ -0,0 +1,18 @@ +BEGIN:VCARD +VERSION:2.1 +N:Gump;Forrest;;Mr. +FN:Forrest Gump +ORG:Bubba Gump Shrimp Co. +TITLE:Shrimp Man +PHOTO;GIF:http://www.example.com/dir_photos/my_photo.gif +TEL;WORK;VOICE:(111) 555-1212 +TEL;HOME;VOICE:(404) 555-1212 +ADR;WORK;PREF:;;100 Waters Edge;Baytown;LA;30314;United States of America +LABEL;WORK;PREF;ENCODING=QUOTED-PRINTABLE;CHARSET=UTF-8:100 Waters Edge=0D= + =0ABaytown\, LA 30314=0D=0AUnited States of America +ADR;HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +LABEL;HOME;ENCODING=QUOTED-PRINTABLE;CHARSET=UTF-8:42 Plantation St.=0D=0A= + Baytown, LA 30314=0D=0AUnited States of America +EMAIL:forrestgump@example.com +REV:20080424T195243Z +END:VCARD diff --git a/test/cases/Merging by single attributes/src/Forrest_Gump.v3.0.vcf b/test/cases/Merging by single attributes/src/Forrest_Gump.v3.0.vcf new file mode 100644 index 0000000..e0b18cd --- /dev/null +++ b/test/cases/Merging by single attributes/src/Forrest_Gump.v3.0.vcf @@ -0,0 +1,16 @@ +BEGIN:VCARD +VERSION:3.0 +N:Gump;Forrest;;Mr.; +FN:Forrest Gump +ORG:Bubba Gump Shrimp Co. +TITLE:Shrimp Man +PHOTO;VALUE=URI;TYPE=GIF:http://www.example.com/dir_photos/my_photo.gif +TEL;TYPE=WORK,VOICE:(111) 555-1212 +TEL;TYPE=HOME,VOICE:(404) 555-1212 +ADR;TYPE=WORK,PREF:;;100 Waters Edge;Baytown;LA;30314;United States of America +LABEL;TYPE=WORK,PREF:100 Waters Edge\nBaytown\, LA 30314\nUnited States of America +ADR;TYPE=HOME:;;42 Plantation St.;Baytown;LA;30314;United States of America +LABEL;TYPE=HOME:42 Plantation St.\nBaytown\, LA 30314\nUnited States of America +EMAIL:forrestgump@example.com +REV:2008-04-24T19:52:43Z +END:VCARD