Add managed content and keyboard usage insights
Introduce versioned official content workflows and privacy-safe keyboard analytics, while preventing repeat DeviceCheck sign-ins from incorrectly restricting eligible accounts.
This commit is contained in:
@@ -51,17 +51,16 @@ class SmokeDeploymentTest : FunSpec({
|
||||
|
||||
test("runtime grants cover every migrated table without mutable history privileges") {
|
||||
val grants = root.read("deploy/smoke/runtime-grants.sql")
|
||||
val migrationTables = (1..17)
|
||||
.flatMap { version ->
|
||||
val migration = Files.list(root.resolve("src/main/resources/db/migration")).use { paths ->
|
||||
paths.filter { it.fileName.toString().startsWith("V${version}__") }
|
||||
.findFirst()
|
||||
.orElseThrow()
|
||||
val migrationTables = Files.list(root.resolve("src/main/resources/db/migration")).use { paths ->
|
||||
paths.filter { MIGRATION_FILE.matches(it.fileName.toString()) }
|
||||
.flatMap { migration ->
|
||||
CREATE_TABLE.findAll(Files.readString(migration))
|
||||
.map { it.groupValues[1] }
|
||||
.toList()
|
||||
.stream()
|
||||
}
|
||||
CREATE_TABLE.findAll(Files.readString(migration))
|
||||
.map { it.groupValues[1] }
|
||||
.toList()
|
||||
}
|
||||
.toList()
|
||||
}
|
||||
.toSet()
|
||||
val grantedTables = GRANTED_TABLE.findAll(grants)
|
||||
.map { it.groupValues[1] }
|
||||
@@ -93,3 +92,4 @@ private fun Path.read(relativePath: String): String =
|
||||
|
||||
private val CREATE_TABLE = Regex("""CREATE TABLE\s+([a-z0-9_]+)""", RegexOption.IGNORE_CASE)
|
||||
private val GRANTED_TABLE = Regex("""ON osg_account_smoke\.([a-z0-9_]+)""")
|
||||
private val MIGRATION_FILE = Regex("""V\d+__.+\.sql""")
|
||||
|
||||
Reference in New Issue
Block a user