-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
169e3ac
commit 31eba31
Showing
13 changed files
with
442 additions
and
5 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
src/test/groovy/net/fortuna/ical4j/extensions/strategy/entity/ApplicationTest.groovy
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
package net.fortuna.ical4j.extensions.strategy.entity | ||
|
||
import net.fortuna.ical4j.vcard.VCardBuilder | ||
import spock.lang.Specification | ||
|
||
class ApplicationTest extends Specification { | ||
|
||
def 'test parsing equivalence'() { | ||
expect: 'parsed model matches strategy' | ||
def application = new Application().withPrototype(prototype).get() | ||
application.propertyList <=> prototype.propertyList == 0 | ||
|
||
and: 'output is valid' | ||
!application.validate().hasErrors() | ||
|
||
where: 'prototype loaded from samples' | ||
prototype << new File('src/test/resources/strategy/application').listFiles().collect { | ||
return new VCardBuilder(new FileInputStream(it)).build().entities | ||
}.flatten() | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
BEGIN:VCARD | ||
VERSION:4.0 | ||
FN:Notion | ||
KIND:APPLICATION | ||
URL:https://www.notion.com/ | ||
END:VCARD |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:resource:collection | ||
SUMMARY:Productivity on the Web | ||
DESCRIPTION:Links and resources for different productivity methodologies and strategies. | ||
LINK;VALUE=URI;LINKREL=related;LABEL=Intro & Overview of Pillars, Pipelines & Vaults – Notion Life OS: | ||
https://youtu.be/d93SGaf82OM?si=KgPq9Hj37sI6xY9j | ||
END:VJOURNAL | ||
END:VCALENDAR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:resource:collection | ||
SUMMARY:Recipes on the Web | ||
DESCRIPTION:Links to various recipes | ||
LINK;VALUE=URI;LINKREL=related;LABEL=How to make scones: | ||
https://www.womensweeklyfood.com.au/recipe/quick-and-easy/basic-scone-22571/ | ||
CATEGORIES:Lifestyle | ||
END:VJOURNAL | ||
END:VCALENDAR |
10 changes: 10 additions & 0 deletions
10
src/test/resources/strategy/collection/working_with_icalendar.ics
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:resource:collection | ||
SUMMARY:Working with iCalendar | ||
DESCRIPTION:Articles on working with the iCalendar specification | ||
LINK;VALUE=URI;LINKREL=related;LABEL=iCalendar, CalDAV & Elixir: | ||
https://blog.swmansion.com/icalendar-caldav-elixir-13be601572eb | ||
CATEGORIES:Education and Employment | ||
END:VJOURNAL | ||
END:VCALENDAR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report | ||
SUMMARY:Monthly Budget Tracker | ||
DTSTART;VALUE=DATE:20250101 | ||
RRULE:FREQ=MONTHLY;INTERVAL=1 | ||
RELATED-TO;VALUE=UID;RELTYPE=CHILD:2 | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report:budget | ||
SUMMARY:Budget - Groceries | ||
DTSTART;VALUE=DATE:20250101 | ||
RRULE:FREQ=MONTHLY;INTERVAL=1 | ||
STRUCTURED-DATA;VALUE=TEXT;FMTTYPE=application/json:{ | ||
"total": 1000, | ||
"remaining": 1000 | ||
} | ||
UID:2 | ||
CATEGORIES:Household | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report:budget | ||
SUMMARY:Groceries | ||
DTSTART;VALUE=DATE:20250101 | ||
SEQUENCE:1 | ||
RECURRENCE-ID;VALUE=DATE:20250101 | ||
RRULE:FREQ=MONTHLY;INTERVAL=1 | ||
STRUCTURED-DATA;VALUE=TEXT;FMTTYPE=application/json:{ | ||
"total": 1000, | ||
"remaining": 735 | ||
} | ||
UID:2 | ||
CATEGORIES:Household | ||
END:VJOURNAL | ||
END:VCALENDAR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,28 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report | ||
SUMMARY:Expense Tracker | ||
SUMMARY:Monthly Expense Tracker | ||
RRULE:FREQ=MONTHLY;INTERVAL=1 | ||
RELATED-TO;VALUE=UID;RELTYPE=CHILD:2 | ||
RELATED-TO;VALUE=UID;RELTYPE=CHILD:3 | ||
RELATED-TO;VALUE=UID;RELTYPE=CHILD:4 | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report:expense | ||
SUMMARY:Groceries | ||
UID:2 | ||
CATEGORIES:Household | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report:expense | ||
SUMMARY:Utilities | ||
UID:3 | ||
CATEGORIES:Household | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report:expense | ||
SUMMARY:Rent/Mortgage | ||
UID:4 | ||
CATEGORIES:Household | ||
END:VJOURNAL | ||
END:VCALENDAR |
14 changes: 14 additions & 0 deletions
14
src/test/resources/strategy/report/investment_portfolio.ics
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
BEGIN:VCALENDAR | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:report | ||
SUMMARY:Investment Portfolio | ||
RRULE:FREQ=WEEKLY;INTERVAL=1 | ||
RELATED-TO;VALUE=UID;RELTYPE=CHILD:2 | ||
END:VJOURNAL | ||
BEGIN:VJOURNAL | ||
CONCEPT:semcal:concept:resource:asset | ||
SUMMARY:AAPL | ||
UID:2 | ||
CATEGORIES:Finance,Investments | ||
END:VJOURNAL | ||
END:VCALENDAR |