#!/bin/bash # SPDX-License-Identifier: MIT function test_forgejo_database_v3_upgrades_list_table() { local table=$1 local work_path=$DIR/forgejo-work-path sqlite3 $work_path/forgejo.db ".tables $table" .exit | grep --quiet $table } function test_forgejo_database_v3_upgrades() { local table=forgejo_auth_token stop reset default log_info "run 1.20.4-1" start 1.20.4-1 stop ! test_forgejo_database_v3_upgrades_list_table $table test_forgejo_database_version 2 log_info "run 1.20.5-0" start 1.20.5-0 stop test_forgejo_database_v3_upgrades_list_table $table test_forgejo_database_version 3 }