Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
9d8a17d
Update ical4j to 4.x and make everything compile again (#197)
rfc2822 Mar 4, 2026
b15da8d
Ignore tests failing due to incomplete ical4j 4.x migration (#206)
cketti Mar 5, 2026
85f4e3c
Update CalendarUidSplitter to support ical4j 4.x (#208)
sunkup Mar 5, 2026
109a4cf
[ical4j 4.x] Update `ICalendarGenerator` and `ICalendarParser` (#209)
cketti Mar 5, 2026
10890df
Merge branch 'main' into ical4j-3to4
cketti Mar 9, 2026
58bc4e7
[ical4j 4.x] Update event validators (#210)
ArnyminerZ Mar 10, 2026
416036d
[ical4j 4.x] Update iCalendar (#215)
sunkup Mar 10, 2026
b63f04a
[ical4j 4.x] Re-enable tests that don't require changes (#220)
cketti Mar 10, 2026
f8b5370
[ical4j 4.x] Migrate event builders part 1 (#223)
cketti Mar 12, 2026
6a35297
"androidify": don't use custom (ical4j) timezones (#226)
rfc2822 Mar 12, 2026
4c10d6a
Add logging for timezone normalization mismatches (#227)
rfc2822 Mar 13, 2026
ba8f247
Update JtxCollection/JtxICalObject (#232)
sunkup Mar 16, 2026
7ae50e9
[ical4j 4.x] Update task property mapping (#218)
ArnyminerZ Mar 16, 2026
2992d01
[ical4j 4.x] Migrate event builders part 2 (#229)
cketti Mar 16, 2026
d1b2d72
Drop `AndroidCompatTimeZoneRegistry` (#233)
rfc2822 Mar 17, 2026
3fe02cc
Update UidHandler and tests
sunkup Mar 17, 2026
658e0cd
Update OriginalInstanceTimeHandler and tests
sunkup Mar 17, 2026
8a6dd5b
Update TitleHandler and tests
sunkup Mar 17, 2026
4ad5639
Update LocationHandler and tests
sunkup Mar 17, 2026
45ee957
Update StartTimeHandler and tests
sunkup Mar 17, 2026
ec52d85
Update EndTimeHandler and tests
sunkup Mar 17, 2026
4d74602
Update DurationHandler and tests
sunkup Mar 17, 2026
6f1c18b
Update DescriptionHandler and tests
sunkup Mar 17, 2026
3f554be
Update ColorHandler and tests
sunkup Mar 17, 2026
3a95444
Update AccessLevelHandler and tests
sunkup Mar 17, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@ androidx-test-runner = "1.7.0"
dokka = "2.1.0"
ezvcard = "0.12.2"
guava = "33.5.0-android"
# noinspection NewerVersionAvailable
ical4j = "3.2.19" # final version; update to 4.x will require much work
ical4j = "4.2.3"
junit = "4.13.2"
kotlin = "2.3.10"
mockk = "1.14.9"
Expand Down
10 changes: 9 additions & 1 deletion lib/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -137,4 +137,12 @@ dependencies {
testImplementation(libs.junit)
testImplementation(libs.mockk)
testImplementation(libs.roboelectric)
}
}

tasks.withType<Test>().configureEach {
options {
// Prevent Robolectric from instrumenting ical4j classes to avoid problems with registering
// ical4j's ZoneRulesProviderImpl more than once with Java's ZoneRulesProvider.
systemProperty("org.robolectric.packagesToNotAcquire", "net.fortuna.ical4j")
}
}
4 changes: 0 additions & 4 deletions lib/consumer-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@
-dontwarn org.codehaus.groovy.**
-dontwarn org.jparsec.**

# keep to be used by ical4j
-keep class at.bitfire.ical4android.AndroidCompatTimeZoneRegistry { *; }
-keep class at.bitfire.ical4android.AndroidCompatTimeZoneRegistry$Factory { *; }

# keep all vCard properties/parameters (used via reflection)
-keep class ezvcard.io.scribe.** { *; }
-keep class ezvcard.property.** { *; }
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,13 @@ package at.bitfire.ical4android
import net.fortuna.ical4j.model.TimeZoneRegistryFactory
import org.junit.Assert
import org.junit.Assert.assertNotNull
import org.junit.Ignore
import org.junit.Test
import java.time.ZoneId
import java.time.format.TextStyle
import java.util.Locale

@Ignore("ical4j 4.x")
class AndroidTimeZonesTest {

@Test
Expand Down
34 changes: 24 additions & 10 deletions lib/src/androidTest/kotlin/at/bitfire/ical4android/DmfsTaskTest.kt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import androidx.core.content.contentValuesOf
import at.bitfire.ical4android.impl.TestTaskList
import at.bitfire.synctools.storage.LocalStorageException
import at.bitfire.synctools.storage.tasks.DmfsTaskList
import net.fortuna.ical4j.model.Date
import net.fortuna.ical4j.model.TimeZoneRegistryFactory
import net.fortuna.ical4j.model.component.VAlarm
import net.fortuna.ical4j.model.parameter.RelType
Expand All @@ -31,6 +30,8 @@ import org.junit.Assert.assertFalse
import org.junit.Assert.assertNotNull
import org.junit.Before
import org.junit.Test
import java.time.LocalDate
import java.time.ZonedDateTime

class DmfsTaskTest(
providerName: TaskProvider.ProviderName
Expand Down Expand Up @@ -87,18 +88,27 @@ class DmfsTaskTest(
task.summary = "Sample event"
task.description = "Sample event with date/time"
task.location = "Sample location"
task.dtStart = DtStart("20150501T120000", tzVienna)
task.due = Due("20150501T140000", tzVienna)
task.dtStart = DtStart(ZonedDateTime.of(
2015, 5, 1,
12, 0, 0, 0,
tzVienna.toZoneId()
))
task.due = Due(ZonedDateTime.of(
2015, 5, 1,
14, 0, 0, 0,
tzVienna.toZoneId()
))
task.organizer = Organizer("mailto:organizer@example.com")
assertFalse(task.isAllDay())

// extended properties
task.categories.addAll(arrayOf("Cat1", "Cat2"))
task.comment = "A comment"

val sibling = RelatedTo("most-fields2@example.com")
sibling.parameters.add(RelType.SIBLING)
task.relatedTo.add(sibling)
task.relatedTo.add(
RelatedTo("most-fields2@example.com")
.add(RelType.SIBLING)
)

task.unknownProperties += XProperty("X-UNKNOWN-PROP", "Unknown Value")

Expand Down Expand Up @@ -133,9 +143,9 @@ class DmfsTaskTest(
val task = Task()
task.uid = "invalidDUE@ical4android.tests"
task.summary = "Task with invalid DUE"
task.dtStart = DtStart(Date("20150102"))
task.dtStart = DtStart(LocalDate.of(2015, 1, 2))

task.due = Due(Date("20150101"))
task.due = Due(LocalDate.of(2015, 1, 1))
DmfsTask(taskList!!, task, "9468a4cf-0d5b-4379-a704-12f1f84100ba", null, 0).add()
}

Expand All @@ -144,7 +154,7 @@ class DmfsTaskTest(
val task = Task()
task.uid = "TaskWithManyAlarms"
task.summary = "Task with many alarms"
task.dtStart = DtStart(Date("20150102"))
task.dtStart = DtStart(LocalDate.of(2015, 1, 2))

for (i in 1..1050)
task.alarms += VAlarm(java.time.Duration.ofMinutes(i.toLong()))
Expand All @@ -162,7 +172,11 @@ class DmfsTaskTest(
task.summary = "Sample event"
task.description = "Sample event with date/time"
task.location = "Sample location"
task.dtStart = DtStart("20150501T120000", tzVienna)
task.dtStart = DtStart(ZonedDateTime.of(
2015, 5, 1,
12, 0, 0, 0,
tzVienna.toZoneId()
))
assertFalse(task.isAllDay())
val uri = DmfsTask(taskList!!, task, "9468a4cf-0d5b-4379-a704-12f1f84100ba", null, 0).add()
assertNotNull(uri)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -837,7 +837,8 @@ class JtxICalObjectTest {
//assertEquals(iCalIn.components[0].getProperty(Component.VTODO), iCalOut.components[0].getProperty(Component.VTODO))

// there should only be one component for VJOURNAL and VTODO!
for(i in 0 until iCalIn.components.size) {
TODO("ical4j 4.x")
/*for(i in 0 until iCalIn.components.size) {

iCalIn.components[i].properties.forEach { inProp ->

Expand All @@ -846,7 +847,7 @@ class JtxICalObjectTest {
val outProp = iCalOut.components[i].properties.getProperty<Property>(inProp.name)
assertEquals(inProp, outProp)
}
}
}*/
}


Expand Down
Loading
Loading