mirror of
https://github.com/dolthub/dolt.git
synced 2026-04-30 11:31:37 -05:00
Merge pull request #6026 from dolthub/nicktobey/no-more-ld1
Remove __LD_1__ from CI
This commit is contained in:
@@ -12,7 +12,7 @@ inputs:
|
||||
format:
|
||||
description: 'dolt noms bin format'
|
||||
required: true
|
||||
default: '__LD_1__'
|
||||
default: '__DOLT__'
|
||||
template:
|
||||
description: 'email template'
|
||||
required: false
|
||||
|
||||
@@ -22,16 +22,12 @@ jobs:
|
||||
fail-fast: true
|
||||
matrix:
|
||||
os: [ ubuntu-22.04, macos-latest ]
|
||||
dolt_fmt: [ "__DOLT__", "__LD_1__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
journal: [ "" ]
|
||||
include:
|
||||
- os: "ubuntu-22.04"
|
||||
dolt_fmt: "__DOLT__"
|
||||
journal: "true"
|
||||
exclude:
|
||||
- os: "macos-latest"
|
||||
dolt_fmt: "__LD_1__"
|
||||
journal: ""
|
||||
env:
|
||||
use_credentials: ${{ secrets.AWS_SECRET_ACCESS_KEY != '' && secrets.AWS_ACCESS_KEY_ID != '' }}
|
||||
steps:
|
||||
|
||||
@@ -18,7 +18,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [ ubuntu-22.04 ]
|
||||
dolt_fmt: [ "__DOLT__", "__LD_1__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
steps:
|
||||
- name: Set up Go 1.x
|
||||
uses: actions/setup-go@v3
|
||||
|
||||
@@ -22,7 +22,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [macos-latest, ubuntu-22.04, windows-latest]
|
||||
dolt_fmt: [ "__DOLT__", "__LD_1__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
journal_store: [ "" ]
|
||||
include:
|
||||
- os: "ubuntu-22.04"
|
||||
@@ -77,7 +77,7 @@ jobs:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [macos-latest, ubuntu-22.04, windows-latest]
|
||||
dolt_fmt: [ "__DOLT__", "__LD_1__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
steps:
|
||||
- name: Set up Go 1.x
|
||||
uses: actions/setup-go@v3
|
||||
|
||||
@@ -22,13 +22,8 @@ jobs:
|
||||
fail-fast: true
|
||||
matrix:
|
||||
os: [ ubuntu-22.04, macos-latest ] # [ ubuntu-22.04, macos-latest, windows-latest ]
|
||||
dolt_fmt: [ "__DOLT__", "__LD_1__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
journal_store: [ "" ]
|
||||
exclude:
|
||||
- os: "macos-latest"
|
||||
dolt_fmt: ["__LD_1__" ]
|
||||
- os: "windows-latest"
|
||||
dolt_fmt: ["__LD_1__" ]
|
||||
include:
|
||||
- os: "ubuntu-22.04"
|
||||
dolt_fmt: "__DOLT__"
|
||||
|
||||
@@ -10,7 +10,7 @@ jobs:
|
||||
name: Dolt SQL Correctness
|
||||
strategy:
|
||||
matrix:
|
||||
dolt_fmt: [ "__LD_1__", "__DOLT__" ]
|
||||
dolt_fmt: [ "__DOLT__" ]
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: azure/setup-kubectl@v3.0
|
||||
|
||||
@@ -103,7 +103,6 @@ SQL
|
||||
dolt commit -m "Added column c2 longtext"
|
||||
dolt checkout main
|
||||
dolt merge branch1
|
||||
skip_nbf_not_dolt
|
||||
dolt merge branch2
|
||||
}
|
||||
|
||||
@@ -129,7 +128,6 @@ SQL
|
||||
dolt commit -m "Added column c0 bigint"
|
||||
dolt checkout main
|
||||
dolt merge branch1
|
||||
skip_nbf_not_dolt
|
||||
dolt merge branch2
|
||||
}
|
||||
|
||||
@@ -304,8 +302,6 @@ DELIM
|
||||
}
|
||||
|
||||
@test "column_tags: update-tag updates a columns tag" {
|
||||
skip_nbf_not_dolt
|
||||
|
||||
dolt sql -q "CREATE TABLE t (pk INT PRIMARY KEY, col1 int);"
|
||||
run dolt schema tags
|
||||
[ $status -eq 0 ]
|
||||
@@ -326,8 +322,6 @@ DELIM
|
||||
}
|
||||
|
||||
@test "column_tags: create table on two separate branches, merge them together even though they have different tags" {
|
||||
skip_nbf_not_dolt
|
||||
|
||||
dolt branch other
|
||||
dolt sql -q "CREATE TABLE t (pk int PRIMARY KEY, col1 int);"
|
||||
dolt sql -q "INSERT INTO t VALUES (1, 1);"
|
||||
|
||||
@@ -74,20 +74,6 @@ skip_nbf_dolt() {
|
||||
fi
|
||||
}
|
||||
|
||||
skip_nbf_not_dolt() {
|
||||
if [ "$DOLT_DEFAULT_BIN_FORMAT" = "__LD_1__" ]
|
||||
then
|
||||
skip "skipping test since nomsBinFormat != __DOLT__"
|
||||
fi
|
||||
}
|
||||
|
||||
skip_nbf_ld_1() {
|
||||
if [ "$DOLT_DEFAULT_BIN_FORMAT" = "__LD_1__" ];
|
||||
then
|
||||
skip "skipping test for nomsBinFormat __LD_1__"
|
||||
fi
|
||||
}
|
||||
|
||||
setup_common() {
|
||||
setup_no_dolt_init
|
||||
dolt init
|
||||
|
||||
@@ -64,7 +64,6 @@ get_conflict_tables() {
|
||||
}
|
||||
|
||||
@test "ignore: simple matches" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -83,7 +82,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: specific overrides" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE please_ignore (pk int);
|
||||
@@ -106,7 +104,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: conflict" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE commit_ignore (pk int);
|
||||
@@ -122,7 +119,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: question mark" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE test (pk int);
|
||||
@@ -141,7 +137,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: don't stash ignored tables" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -154,7 +149,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: error when trying to stash table with dolt_ignore conflict" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE commit_ignore (pk int);
|
||||
@@ -169,7 +163,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: stash ignored and untracked tables when --all is passed" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -194,7 +187,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: stash table with dolt_ignore conflict when --all is passed" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE commit_ignore (pk int);
|
||||
@@ -215,7 +207,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: allow staging ignored tables if 'add --force' is supplied" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -229,7 +220,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: don't auto-stage ignored tables" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -247,7 +237,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: dolt status doesn't show ignored tables when --ignored is not supplied" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -265,7 +254,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: dolt status shows ignored tables when --ignored is not supplied" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -283,7 +271,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: don't display new but ignored tables in dolt diff" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -299,7 +286,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: don't display new but ignored tables in reverse diff" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -315,7 +301,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: DO display modified ignored tables in dolt diff after staging" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -337,7 +322,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: DO display modified ignored tables in reverse diff after staging" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -359,7 +343,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: DO display modified ignored tables in dolt diff after committing" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
CREATE TABLE ignoreme (pk int);
|
||||
@@ -382,7 +365,6 @@ SQL
|
||||
}
|
||||
|
||||
@test "ignore: detect when equivalent patterns have different values" {
|
||||
skip_nbf_ld_1
|
||||
|
||||
dolt sql <<SQL
|
||||
INSERT INTO dolt_ignore VALUES
|
||||
|
||||
@@ -584,7 +584,6 @@ DELIM
|
||||
|
||||
# assert that we already collected garbage
|
||||
BEFORE=$(du -c .dolt/noms/ | grep total | sed 's/[^0-9]*//g')
|
||||
skip_nbf_dolt "dolt gc not implemented"
|
||||
dolt gc
|
||||
AFTER=$(du -c .dolt/noms/ | grep total | sed 's/[^0-9]*//g')
|
||||
|
||||
|
||||
@@ -191,47 +191,6 @@ teardown() {
|
||||
[[ $output =~ "NEW ( __DOLT__ )" ]] || false
|
||||
}
|
||||
|
||||
@test "init: initing an old database displays the correct version" {
|
||||
set_dolt_user "baz", "bazbash.com"
|
||||
|
||||
DOLT_DEFAULT_BIN_FORMAT="__LD_1__" dolt init
|
||||
|
||||
run dolt version
|
||||
[ "$status" -eq 0 ]
|
||||
[[ $output =~ "database storage format: OLD ( __LD_1__ )" ]] || false
|
||||
|
||||
run dolt sql -q "SELECT dolt_storage_format();"
|
||||
[[ $output =~ "OLD ( __LD_1__ )" ]] || false
|
||||
}
|
||||
|
||||
@test "init: get format in multiple database mode" {
|
||||
orig_bin_format=$DOLT_DEFAULT_BIN_FORMAT
|
||||
|
||||
mkdir old_fmt
|
||||
cd old_fmt
|
||||
DOLT_DEFAULT_BIN_FORMAT="__LD_1__" dolt init
|
||||
cd ..
|
||||
|
||||
mkdir new_fmt
|
||||
cd new_fmt
|
||||
DOLT_DEFAULT_BIN_FORMAT="__DOLT__" dolt init
|
||||
cd ..
|
||||
|
||||
# New format db gets chosen automatically, as it is the only db loaded
|
||||
export DOLT_DEFAULT_BIN_FORMAT="__DOLT__"
|
||||
run dolt sql -q "SELECT dolt_storage_format()"
|
||||
[ $status -eq 0 ]
|
||||
[[ $output =~ "NEW ( __DOLT__ )" ]] || false
|
||||
|
||||
# Old format db gets chosen automatically, as it is the only db loaded
|
||||
export DOLT_DEFAULT_BIN_FORMAT="__LD_1__"
|
||||
run dolt sql -q "SELECT dolt_storage_format()"
|
||||
[ $status -eq 0 ]
|
||||
[[ $output =~ "OLD ( __LD_1__ )" ]] || false
|
||||
|
||||
export DOLT_DEFAULT_BIN_FORMAT=$orig_bin_format
|
||||
}
|
||||
|
||||
@test "init: empty database folder displays no version" {
|
||||
set_dolt_user "baz", "bazbash.com"
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@ load $BATS_TEST_DIRNAME/helper/common.bash
|
||||
|
||||
setup() {
|
||||
setup_common
|
||||
skip_nbf_not_dolt
|
||||
}
|
||||
|
||||
teardown() {
|
||||
|
||||
@@ -3,7 +3,6 @@ load $BATS_TEST_DIRNAME/helper/common.bash
|
||||
|
||||
setup() {
|
||||
setup_common
|
||||
skip_nbf_dolt "works fine but formatting of json strings is different"
|
||||
}
|
||||
|
||||
teardown() {
|
||||
|
||||
@@ -3,7 +3,6 @@ load $BATS_TEST_DIRNAME/helper/common.bash
|
||||
|
||||
setup() {
|
||||
setup_common
|
||||
skip_nbf_not_dolt
|
||||
}
|
||||
|
||||
teardown() {
|
||||
|
||||
@@ -1,84 +0,0 @@
|
||||
#!/usr/bin/env bats
|
||||
load $BATS_TEST_DIRNAME/helper/common.bash
|
||||
|
||||
setup() {
|
||||
skip_nbf_dolt
|
||||
|
||||
setup_common
|
||||
TARGET_NBF="__DOLT__"
|
||||
}
|
||||
|
||||
teardown() {
|
||||
teardown_common
|
||||
}
|
||||
|
||||
@test "migration-integration: first-hour-db" {
|
||||
dolt clone https://doltremoteapi.dolthub.com/dolthub/first-hour-db-migration-int
|
||||
cd first-hour-db-migration-int
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "r9jv07tf9un3fm1fg72v7ad9er89oeo7" ]] || false
|
||||
[[ ! "$output" =~ "4v7c07ht4o7eshlcmgc9ciop0780lerv" ]] || false
|
||||
|
||||
dolt migrate
|
||||
[[ $(cat ./.dolt/noms/manifest | cut -f 2 -d :) = "$TARGET_NBF" ]] || false
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "4v7c07ht4o7eshlcmgc9ciop0780lerv" ]] || false
|
||||
[[ ! "$output" =~ "r9jv07tf9un3fm1fg72v7ad9er89oeo7" ]] || false
|
||||
|
||||
# validate TEXT migration
|
||||
run dolt sql -q "select film_id, title from film order by film_id limit 1" -r csv
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "1,ACADEMY DINOSAUR" ]] || false
|
||||
}
|
||||
|
||||
@test "migration-integration: first-hour-db after garbage collection" {
|
||||
dolt clone https://doltremoteapi.dolthub.com/dolthub/first-hour-db-migration-int
|
||||
cd first-hour-db-migration-int
|
||||
dolt gc
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "r9jv07tf9un3fm1fg72v7ad9er89oeo7" ]] || false
|
||||
[[ ! "$output" =~ "4v7c07ht4o7eshlcmgc9ciop0780lerv" ]] || false
|
||||
|
||||
dolt migrate
|
||||
[[ $(cat ./.dolt/noms/manifest | cut -f 2 -d :) = "$TARGET_NBF" ]] || false
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "4v7c07ht4o7eshlcmgc9ciop0780lerv" ]] || false
|
||||
[[ ! "$output" =~ "r9jv07tf9un3fm1fg72v7ad9er89oeo7" ]] || false
|
||||
|
||||
# validate TEXT migration
|
||||
run dolt sql -q "select film_id, title from film order by film_id limit 1" -r csv
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "1,ACADEMY DINOSAUR" ]] || false
|
||||
}
|
||||
|
||||
@test "migration-integration: us-jails" {
|
||||
dolt clone https://doltremoteapi.dolthub.com/dolthub/us-jails-migration-integration
|
||||
cd us-jails-migration-integration
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "u8s83gapv7ghnbmrtpm8q5es0dbl7lpd" ]] || false
|
||||
[[ ! "$output" =~ "nm1ubfu85p4c082bhertltrhkkeffaqg" ]] || false
|
||||
|
||||
dolt migrate
|
||||
[[ $(cat ./.dolt/noms/manifest | cut -f 2 -d :) = "$TARGET_NBF" ]] || false
|
||||
|
||||
dolt tag -v
|
||||
run dolt tag -v
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "nm1ubfu85p4c082bhertltrhkkeffaqg" ]] || false
|
||||
[[ ! "$output" =~ "u8s83gapv7ghnbmrtpm8q5es0dbl7lpd" ]] || false
|
||||
}
|
||||
@@ -346,13 +346,6 @@ NOT_VALID_REPO_ERROR="The current directory is not a valid dolt repository."
|
||||
[[ "$output" =~ "Failed to load the HOME directory" ]]
|
||||
}
|
||||
|
||||
@test "no-repo: init with new storage version" {
|
||||
DOLT_DEFAULT_BIN_FORMAT="__DOLT__" dolt init
|
||||
run cat .dolt/noms/manifest
|
||||
[[ "$output" =~ "__DOLT__" ]]
|
||||
[[ ! "$output" =~ "__LD_1__" ]]
|
||||
}
|
||||
|
||||
@test "no-repo: dolt login exits when receiving SIGINT" {
|
||||
dolt login & # run this in the background
|
||||
PID=$! # capture background PID
|
||||
|
||||
@@ -3,7 +3,6 @@ load $BATS_TEST_DIRNAME/helper/common.bash
|
||||
|
||||
setup() {
|
||||
setup_common
|
||||
skip_nbf_not_dolt
|
||||
}
|
||||
|
||||
teardown() {
|
||||
|
||||
@@ -123,7 +123,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: --no-pretty" {
|
||||
skip_nbf_ld_1
|
||||
dolt commit --allow-empty -m "commit: initialize table1"
|
||||
run dolt show --no-pretty
|
||||
[ $status -eq 0 ]
|
||||
@@ -141,7 +140,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: HEAD root" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "create table table1 (pk int PRIMARY KEY)"
|
||||
dolt sql -q "insert into table1 values (1), (2), (3)"
|
||||
dolt add .
|
||||
@@ -164,7 +162,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: WORKING" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "create table table1 (pk int PRIMARY KEY)"
|
||||
dolt sql -q "insert into table1 values (1), (2), (3)"
|
||||
dolt add .
|
||||
@@ -182,7 +179,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: STAGED" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "create table table1 (pk int PRIMARY KEY)"
|
||||
dolt sql -q "insert into table1 values (1), (2), (3)"
|
||||
dolt add .
|
||||
@@ -200,7 +196,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: table" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "create table table1 (pk int PRIMARY KEY)"
|
||||
dolt sql -q "insert into table1 values (1), (2), (3)"
|
||||
dolt add .
|
||||
@@ -223,7 +218,6 @@ assert_has_key_value() {
|
||||
}
|
||||
|
||||
@test "show: pretty commit from hash" {
|
||||
skip_nbf_ld_1
|
||||
dolt tag v0
|
||||
dolt commit --allow-empty -m "commit1"
|
||||
|
||||
@@ -234,25 +228,7 @@ assert_has_key_value() {
|
||||
[[ "$output" =~ "tag: v0" ]] || false
|
||||
}
|
||||
|
||||
@test "show: --no-pretty with old format" {
|
||||
skip_nbf_dolt
|
||||
|
||||
run dolt show --no-pretty
|
||||
[ $status -eq 1 ]
|
||||
[[ "$output" =~ "dolt show --no-pretty is not supported when using old LD_1 storage format." ]] || false
|
||||
}
|
||||
|
||||
@test "show: non-commit object with old format" {
|
||||
skip_nbf_dolt
|
||||
|
||||
run dolt show WORKING
|
||||
[ $status -eq 1 ]
|
||||
[[ "$output" =~ "dolt show cannot show non-commit objects when using the old LD_1 storage format: WORKING is not a commit" ]] || false
|
||||
}
|
||||
|
||||
@test "show: non-existent branch" {
|
||||
skip_nbf_dolt
|
||||
|
||||
run dolt show branch1
|
||||
[ $status -eq 1 ]
|
||||
[[ "$output" =~ "branch not found: branch1" ]] || false
|
||||
|
||||
@@ -11,7 +11,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "spatial-index: spatial indexes enabled" {
|
||||
skip_nbf_not_dolt
|
||||
run dolt sql -q "create table t (p point srid 0 not null, spatial index(p))"
|
||||
[ "$status" -eq 0 ]
|
||||
}
|
||||
|
||||
@@ -909,7 +909,6 @@ SQL
|
||||
[[ "$output" =~ "CONSTRAINT \`c1\` CHECK ((\`i\` < 0))" ]] || false
|
||||
dolt commit -am "changes to main"
|
||||
|
||||
skip_nbf_not_dolt
|
||||
dolt merge other -m "merge other"
|
||||
|
||||
run dolt status
|
||||
@@ -974,7 +973,6 @@ SQL
|
||||
[[ "$output" =~ "CONSTRAINT \`c\` CHECK ((\`i\` < 10))" ]] || false
|
||||
dolt commit -am "changes to main"
|
||||
|
||||
skip_nbf_not_dolt
|
||||
dolt merge other -m "merge other"
|
||||
run dolt status
|
||||
log_status_eq 0
|
||||
@@ -1047,7 +1045,6 @@ SQL
|
||||
dolt checkout main
|
||||
run dolt merge b1 -m "merge b1" --commit
|
||||
log_status_eq 0
|
||||
skip_nbf_not_dolt
|
||||
dolt merge b2 -m "merge b2"
|
||||
run dolt status
|
||||
log_status_eq 0
|
||||
@@ -1083,7 +1080,6 @@ SQL
|
||||
dolt checkout main
|
||||
run dolt merge b1 -m "merge b1"
|
||||
log_status_eq 0
|
||||
skip_nbf_not_dolt
|
||||
dolt merge b2 -m "merge b2"
|
||||
run dolt status
|
||||
log_status_eq 0
|
||||
|
||||
@@ -14,25 +14,13 @@ teardown() {
|
||||
teardown_common
|
||||
}
|
||||
|
||||
@test "stash: stash is not supported for old format" {
|
||||
if [ "$DOLT_DEFAULT_BIN_FORMAT" = "__LD_1__" ]; then
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
|
||||
run dolt stash
|
||||
[ "$status" -eq 1 ]
|
||||
[[ "$output" =~ "stash is not supported for old storage format" ]] || false
|
||||
fi
|
||||
}
|
||||
|
||||
@test "stash: stashing on clean working set" {
|
||||
skip_nbf_ld_1
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
[[ "$output" =~ "No local changes to save" ]] || false
|
||||
}
|
||||
|
||||
@test "stash: simple stashing and popping stash" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt sql -q "SELECT * FROM test"
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -61,7 +49,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: clearing stash when stash list is empty" {
|
||||
skip_nbf_ld_1
|
||||
run dolt stash list
|
||||
[ "$status" -eq 0 ]
|
||||
[ "${#lines[@]}" -eq 0 ]
|
||||
@@ -72,7 +59,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: clearing stash removes all entries in stash list" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
dolt stash
|
||||
|
||||
@@ -95,7 +81,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: clearing stash and stashing again" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
dolt stash
|
||||
|
||||
@@ -114,7 +99,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: clearing stash and popping returns error of no entries found" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
dolt stash
|
||||
dolt sql -q "INSERT INTO test VALUES (2, 'b')"
|
||||
@@ -143,7 +127,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping oldest stash" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -176,7 +159,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping neither latest nor oldest stash" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -229,7 +211,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing multiple entries on different branches" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -246,7 +227,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash on different branch" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -264,7 +244,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: dropping stash removes an entry at given index in stash list" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -309,7 +288,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash on dirty working set with no conflict" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -330,7 +308,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash on dirty working set with conflict" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt stash
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -351,7 +328,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing both modified staged and working set of changes and popping the stash" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
dolt add .
|
||||
dolt sql -q "INSERT INTO test VALUES (2, 'b')"
|
||||
@@ -385,7 +361,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing on working set with untracked tables only should be nothing to stash" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "CREATE TABLE new_table (id INT PRIMARY KEY);"
|
||||
|
||||
run dolt status
|
||||
@@ -403,7 +378,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing untracked tables with --include-untracked flag and popping the table should not be staged" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "CREATE TABLE new_table (id INT PRIMARY KEY);"
|
||||
dolt add .
|
||||
dolt sql -q "CREATE TABLE test_table (id INT);"
|
||||
@@ -429,7 +403,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing staged new table changes and popping the stash, the added table should be staged" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "CREATE TABLE new_table (id INT PRIMARY KEY);"
|
||||
dolt add .
|
||||
|
||||
@@ -463,7 +436,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing with staged, working set changes with untracked tables should only stash modified working set and staged changes" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "CREATE TABLE new_table (id INT PRIMARY KEY);"
|
||||
dolt add .
|
||||
dolt sql -q "INSERT INTO new_table VALUES (1),(2);"
|
||||
@@ -500,7 +472,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: stashing working set with deleted table and popping it" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "CREATE TABLE new_table (id INT PRIMARY KEY);"
|
||||
dolt commit -Am "create new table"
|
||||
|
||||
@@ -533,7 +504,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: simple stashing and popping stash after running GC" {
|
||||
skip_nbf_ld_1
|
||||
dolt sql -q "INSERT INTO test VALUES (1, 'a')"
|
||||
run dolt sql -q "SELECT * FROM test"
|
||||
[ "$status" -eq 0 ]
|
||||
@@ -568,7 +538,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash with deleted table that is deleted already on current head" {
|
||||
skip_nbf_ld_1
|
||||
dolt branch branch1
|
||||
dolt checkout -b branch2
|
||||
dolt sql -q "DROP TABLE test;"
|
||||
@@ -597,7 +566,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash with deleted table that the same table exists on current head" {
|
||||
skip_nbf_ld_1
|
||||
dolt branch branch1
|
||||
dolt branch branch2
|
||||
|
||||
@@ -630,7 +598,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash with deleted table that different table with same name on current head gives conflict" {
|
||||
skip_nbf_ld_1
|
||||
dolt branch branch1
|
||||
dolt branch branch2
|
||||
|
||||
@@ -661,7 +628,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash with added table with PK on current head with the exact same table is added already" {
|
||||
skip_nbf_ld_1
|
||||
dolt branch branch1
|
||||
dolt checkout -b branch2
|
||||
dolt sql -q "CREATE TABLE new_test(id INT PRIMARY KEY); INSERT INTO new_test VALUES (1);"
|
||||
@@ -691,7 +657,6 @@ teardown() {
|
||||
}
|
||||
|
||||
@test "stash: popping stash with added keyless table on current head with the exact same table is added already" {
|
||||
skip_nbf_ld_1
|
||||
dolt branch branch1
|
||||
dolt checkout -b branch2
|
||||
dolt sql -q "CREATE TABLE new_test(id INT); INSERT INTO new_test VALUES (1);"
|
||||
|
||||
Reference in New Issue
Block a user