Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,7 @@ data class ReleaseContent(val subtext: String, val changes: List<Change>) {
* ]
* ```
*/
val CHANGE_REGEX = Regex("^\\* ([\\s\\S]+?)(?=^\\*|(?![\\s\\S]))", RegexOption.MULTILINE)
val CHANGE_REGEX = "^[*-] ([\\s\\S]+?)(?=^[*-]|(?![\\s\\S]))".toRegex(RegexOption.MULTILINE)

/**
* Regex for finding the subtext in a release.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ abstract class MakeReleaseNotesTask : DefaultTask() {
*/
private val LINK_REGEX =
Regex(
"(?:GitHub )?(?:\\[|\\()#(\\d+)(?:\\]|\\))(?:\\(.+?\\))?(?:\\{: \\.external\\})?",
"(?:GitHub )?(?:\\[|\\()#(\\d+)(?:\\]|\\))(?:\\(.+?\\))?(?:\\{:\\s*\\.external\\})?",
RegexOption.MULTILINE,
)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@
package com.google.firebase.gradle.plugins

import io.kotest.core.spec.style.FunSpec
import io.kotest.matchers.collections.beEmpty
import io.kotest.matchers.file.exist
import io.kotest.matchers.should
import io.kotest.matchers.file.shouldExist
import io.kotest.matchers.shouldBe
import java.io.File
import org.gradle.testkit.runner.GradleRunner
import org.junit.BeforeClass
Expand All @@ -39,9 +38,8 @@ class MakeReleaseNotesTests : FunSpec() {
"firebase-storage/build/tmp/makeReleaseNotes/release_notes.md"
)

releaseNoteFile should exist()

releaseNoteFile.readLines() diff expectedReleaseNoteFile.readLines() should beEmpty()
releaseNoteFile.shouldExist()
releaseNoteFile.readText() shouldBe expectedReleaseNoteFile.readText()
}

private fun buildReleaseNotes() =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import io.kotest.matchers.collections.shouldContainExactly
import io.kotest.matchers.collections.shouldHaveAtLeastSize
import io.kotest.matchers.collections.shouldHaveSize
import io.kotest.matchers.shouldBe
import io.kotest.matchers.string.shouldMatch
import java.io.File
import org.gradle.testkit.runner.GradleRunner
import org.junit.BeforeClass
Expand Down Expand Up @@ -102,7 +101,7 @@ class MoveUnreleasedChangesTests : FunSpec() {
val originalEntry = original.releases.first()

releasedEntry.content.changes shouldContainExactly originalEntry.content.changes
releasedEntry.content.subtext shouldMatch originalEntry.content.subtext
releasedEntry.content.subtext shouldBe originalEntry.content.subtext
}

companion object {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ Note: We did some super cool stuff here!
- [feature] Added support for disjunctions in queries (`OR` queries).

- [feature] Firebase now supports Kotlin coroutines. With this release, we added
[`kotlinx-coroutines-play-services`](https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-play-services/){:
.external} to `firebase-firestore-ktx` as a transitive dependency, which exposes the
[`kotlinx-coroutines-play-services`](https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-play-services/){:.external} to `firebase-firestore-ktx` as a transitive dependency, which exposes the
`Task<T>.await()` suspend function to convert a
[`Task`](https://developers.google.com/android/guides/tasks) into a Kotlin coroutine.

Expand All @@ -15,7 +14,7 @@ Note: We did some super cool stuff here!
- [removed] Removed some old stuff (#562)

- [feature] Added this thing we wanted
[#444](//github.com/firebase/firebase-android-sdk/issues/number){: .external}
[#444](//github.com/firebase/firebase-android-sdk/issues/number){:.external}

- [feature] Added
[`Query.snapshots()`](/docs/reference/kotlin/com/google/firebase/firestore/ktx/package-summary#snapshots_1)
Expand Down Expand Up @@ -45,7 +44,7 @@ Note: We did some super cool stuff here!
# 24.5.0

- [fixed] Fixed stack overflow caused by deeply nested server timestamps. (GitHub
[#4702](//github.com/firebase/firebase-android-sdk/issues/4702){: .external})
[#4702](//github.com/firebase/firebase-android-sdk/issues/4702){:.external})

## Kotlin

Expand Down
27 changes: 12 additions & 15 deletions plugins/src/test/resources/MakeReleaseNotes/release-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,32 +2,29 @@

Note: We did some super cool stuff here!

- {{feature}} Added support for disjunctions in queries (`OR` queries).
* {{feature}} Added support for disjunctions in queries (`OR` queries).

- {{feature}} Firebase now supports Kotlin coroutines. With this release, we added
[`kotlinx-coroutines-play-services`](https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-play-services/){:
.external} to `firebase-firestore-ktx` as a transitive dependency, which exposes the
* {{feature}} Firebase now supports Kotlin coroutines. With this release, we added
[`kotlinx-coroutines-play-services`](https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-play-services/){:.external} to `firebase-firestore-ktx` as a transitive dependency, which exposes the
`Task<T>.await()` suspend function to convert a
[`Task`](https://developers.google.com/android/guides/tasks) into a Kotlin coroutine.

- {{fixed}} An issue on GitHub [#123](//github.com/firebase/firebase-android-sdk/issues/123){:
.external}
* {{fixed}} An issue on GitHub [#123](//github.com/firebase/firebase-android-sdk/issues/123){: .external}

- {{removed}} Removed some old stuff GitHub
[#562](//github.com/firebase/firebase-android-sdk/issues/562){: .external}
* {{removed}} Removed some old stuff GitHub [#562](//github.com/firebase/firebase-android-sdk/issues/562){: .external}

- {{feature}} Added this thing we wanted GitHub
[#444](//github.com/firebase/firebase-android-sdk/issues/444){: .external}
* {{feature}} Added this thing we wanted
GitHub [#444](//github.com/firebase/firebase-android-sdk/issues/444){: .external}

- {{feature}} Added
* {{feature}} Added
[`Query.snapshots()`](/docs/reference/kotlin/com/google/firebase/firestore/ktx/package-summary#snapshots_1)
and
[`DocumentReference.snapshots()`](/docs/reference/kotlin/com/google/firebase/firestore/ktx/package-summary#snapshots)
Kotlin Flows to listen for realtime updates.

- {{fixed}} Fixed an issue in `waitForPendingWrites()` that could lead to a `NullPointerException`.
* {{fixed}} Fixed an issue in `waitForPendingWrites()` that could lead to a `NullPointerException`.

- {{feature}} Added
* {{feature}} Added
[`Query.whereNotIn()`](</docs/reference/android/com/google/firebase/firestore/Query#whereNotIn(java.lang.String,%20java.util.List<?%20extends%20java.lang.Object)>>)
and
[`Query.whereNotEqualTo()`](</docs/reference/android/com/google/firebase/firestore/Query#whereNotEqualTo(java.lang.String,%20java.lang.Object)>)
Expand All @@ -40,6 +37,6 @@ Note: We did some super cool stuff here!

Neither query operator finds documents where the specified field isn't present.

- {{unchanged}} Idk ig we did some stuff
* {{unchanged}} Idk ig we did some stuff

- {{removed}} some stuff that we didn't really like got removed
* {{removed}} some stuff that we didn't really like got removed
Loading