Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Divided into tests: - box/ddl_alter.test.lua - box/ddl_collation.test.lua - box/ddl_collation_types.test.lua - box/ddl_collation_wrong_id.test.lua - box/ddl_no_collation.test.lua - box/ddl_parallel.test.lua - box/ddl_tuple.test.lua - box/gh-2336-ddl_call_twice.test.lua - box/gh-2783-ddl_lock.test.lua - box/gh-2839-ddl_custom_fields.test.lua - box/gh-2937-ddl_collation_field_def.test.lua - box/gh-3290-ddl_collation_deleted.test.lua - box/gh-928-ddl_truncate.test.lua
- Loading branch information
Showing
28 changed files
with
1,539 additions
and
1,482 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
-- test-run result file version 2 | ||
-- index should not crash after alter | ||
space = box.schema.space.create('test_swap') | ||
| --- | ||
| ... | ||
index = space:create_index('pk') | ||
| --- | ||
| ... | ||
space:replace({1, 2, 3}) | ||
| --- | ||
| - [1, 2, 3] | ||
| ... | ||
index:rename('primary') | ||
| --- | ||
| ... | ||
index2 = space:create_index('sec') | ||
| --- | ||
| ... | ||
space:replace({2, 3, 1}) | ||
| --- | ||
| - [2, 3, 1] | ||
| ... | ||
space:select() | ||
| --- | ||
| - - [1, 2, 3] | ||
| - [2, 3, 1] | ||
| ... | ||
space:drop() | ||
| --- | ||
| ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
-- index should not crash after alter | ||
space = box.schema.space.create('test_swap') | ||
index = space:create_index('pk') | ||
space:replace({1, 2, 3}) | ||
index:rename('primary') | ||
index2 = space:create_index('sec') | ||
space:replace({2, 3, 1}) | ||
space:select() | ||
space:drop() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
-- test-run result file version 2 | ||
-- gh-2336 crash if format called twice during snapshot | ||
fiber = require'fiber' | ||
| --- | ||
| ... | ||
|
||
space = box.schema.space.create('test_format') | ||
| --- | ||
| ... | ||
_ = space:create_index('pk', { parts = { 1,'str' }}) | ||
| --- | ||
| ... | ||
space:format({{ name ="key"; type = "string" }, { name ="dataAB"; type = "string" }}) | ||
| --- | ||
| ... | ||
str = string.rep("t",1024) | ||
| --- | ||
| ... | ||
for i = 1, 10000 do space:insert{tostring(i), str} end | ||
| --- | ||
| ... | ||
ch = fiber.channel(3) | ||
| --- | ||
| ... | ||
_ = fiber.create(function() fiber.yield() box.snapshot() ch:put(true) end) | ||
| --- | ||
| ... | ||
format = {{name ="key"; type = "string"}, {name ="data"; type = "string"}} | ||
| --- | ||
| ... | ||
for i = 1, 2 do fiber.create(function() fiber.yield() space:format(format) ch:put(true) end) end | ||
| --- | ||
| ... | ||
|
||
{ch:get(), ch:get(), ch:get()} | ||
| --- | ||
| - - true | ||
| - true | ||
| - true | ||
| ... | ||
|
||
space:drop() | ||
| --- | ||
| ... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
-- gh-2336 crash if format called twice during snapshot | ||
fiber = require'fiber' | ||
|
||
space = box.schema.space.create('test_format') | ||
_ = space:create_index('pk', { parts = { 1,'str' }}) | ||
space:format({{ name ="key"; type = "string" }, { name ="dataAB"; type = "string" }}) | ||
str = string.rep("t",1024) | ||
for i = 1, 10000 do space:insert{tostring(i), str} end | ||
ch = fiber.channel(3) | ||
_ = fiber.create(function() fiber.yield() box.snapshot() ch:put(true) end) | ||
format = {{name ="key"; type = "string"}, {name ="data"; type = "string"}} | ||
for i = 1, 2 do fiber.create(function() fiber.yield() space:format(format) ch:put(true) end) end | ||
|
||
{ch:get(), ch:get(), ch:get()} | ||
|
||
space:drop() |
Oops, something went wrong.