[Tarantool-patches] [PATCH] net.box: fix fetching of schema of an old version

Alexander Turenko alexander.turenko at tarantool.org
Sun Apr 19 19:23:27 MSK 2020


> > It seems logical to move snapshots out from test suites, since they will
> > be used across the test suites. What do you think?
> 
> It is not always the case. A snapshot is ok to use across tests only if
> it is not related to any particular test more than to others. Only empty
> snapshots satisfy that criteria. The reason is that we are obligated to
> keep tests isolated from each other. And if you use one non-empty snapshot
> for multiple tests, the policy will be violated.

(Continued snap/upgrade discussion in the sibling email thread.)

How about this directory structure?

 test/
 |
 +- snap/
    |
    +- how_to_add_new_test.md
    |
    +- xlog/
    |  |
    |  +- gh-4771-upgrade-sequence/
    |     |
    |     +- fill.lua
    |     +- 2.1.3/
    |        |
    |        +- *.snap
    |
    +- box-tap/
       |
       +- gh-4691-net-box-connect-schema-2-1-3/
          |
          +- fill.lua
          +- 2.1.3/
             |
             +- *.snap

Key points:

* All snapshots are in one place: it is easier to keep them right
  structured.
* Snapshots are organized on per-test basis.

Alternative:

 test/
 |
 +- xlog/
 |  |
 |  +- snap/
 |     |
 |     +- how_to_add_new_test.md
 |     |
 |     +- gh-4771-upgrade-sequence/
 |        |
 |        +- fill.lua
 |        +- 2.1.3/
 |           |
 |           +- *.snap
 |
 +- box-tap/
    |
    +- snap/
       |
       +- how_to_add_new_test.md -> ../../xlog/snap/how_to_add_new_test.md
       |
       +- gh-4691-net-box-connect-schema-2-1-3/
          |
          +- fill.lua
          +- 2.1.3/
             |
             +- *.snap

Key points:

* All snapshots organized as same structured subtrees.
* Same as above, snapshots are organized on per-test basis.

WBR, Alexander Turenko.


More information about the Tarantool-patches mailing list