Skip to content
Open
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
3 changes: 3 additions & 0 deletions Schema/app/007-installation-indexing.blue.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
INSERT INTO odin.migration VALUES('app', '007-installation-indexing.blue.sql');

CREATE INDEX IF NOT EXISTS idx_app_installation_id ON odin.app_user_installation_id_ledger (app_id, installation_id);
7 changes: 7 additions & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
../Schema/opts/email/001-initial.blue.sql
../Schema/opts/email/003-alter-ledgers.blue.sql
../Schema/opts/email/004-merge-account-function.blue.sql
Expand Down Expand Up @@ -504,6 +505,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
../Configuration/odin-views.json
app-installation.fg
)
Expand Down Expand Up @@ -535,6 +537,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
../Configuration/odin-views.json
app.mint-test.json
app.mint.fg
Expand Down Expand Up @@ -566,6 +569,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
../Configuration/odin-views.json
app-login.fg
)
Expand Down Expand Up @@ -681,6 +685,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
app-secure-test-view.json
app-secure.fg
)
Expand Down Expand Up @@ -710,6 +715,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
app-verify.fg
)

Expand Down Expand Up @@ -744,6 +750,7 @@ if(TARGET stress OR TARGET pgtest)
../Schema/app/004-app-installation.blue.sql
../Schema/app/005-alter-ledgers.blue.sql
../Schema/app/006-merge-account-function.blue.sql
../Schema/app/007-installation-indexing.blue.sql
../Schema/opts/full-name/001-initial.blue.sql
../Schema/opts/full-name/003-alter-ledgers.blue.sql
../Schema/opts/full-name/004-merge-account-function.blue.sql
Expand Down
1 change: 1 addition & 0 deletions tests/app-handover.fg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

# Set up new users and apps
odin.user owner owner password1234
Expand Down
1 change: 1 addition & 0 deletions tests/app-installation.fg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

# Set up apps
sql.insert odin.identity {"id": "invited-only-app"}
Expand Down
1 change: 1 addition & 0 deletions tests/app-login-facebook.fg
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

setting odin "JWT secret" <JWT_SECRET>
setting odin "Facebook API Endpoint" "https://graph.facebook.com/v3.2"
Expand Down
1 change: 1 addition & 0 deletions tests/app-login-google.fg
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

setting odin "JWT secret" <JWT_SECRET>

Expand Down
1 change: 1 addition & 0 deletions tests/app-login.fg
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ POST odin/app /login/invite-only-app/ {"username": "player2", "password": "passw
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

sql.insert odin.identity {"id": "open-app"}
sql.insert odin.app_ledger {
Expand Down
1 change: 1 addition & 0 deletions tests/app-secure.fg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

# Set up new users and apps
odin.user owner owner password1234
Expand Down
1 change: 1 addition & 0 deletions tests/app-verify.fg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

# Set up new users and apps
odin.user owner owner password1234
Expand Down
1 change: 1 addition & 0 deletions tests/app.mint.fg
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)

sql.insert odin.identity {"id": "bowling"}
sql.insert odin.app_ledger {
Expand Down
1 change: 1 addition & 0 deletions tests/merge-account.fg
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ odin.sql.file (module.path.join ../Schema/app/003-app-role.blue.sql)
odin.sql.file (module.path.join ../Schema/app/004-app-installation.blue.sql)
odin.sql.file (module.path.join ../Schema/app/005-alter-ledgers.blue.sql)
odin.sql.file (module.path.join ../Schema/app/006-merge-account-function.blue.sql)
odin.sql.file (module.path.join ../Schema/app/007-installation-indexing.blue.sql)
# module opts/email
odin.sql.file (module.path.join ../Schema/opts/email/001-initial.blue.sql)
odin.sql.file (module.path.join ../Schema/opts/email/003-alter-ledgers.blue.sql)
Expand Down