Skip to content

Commit 0915260

Browse files
committed
crud: draft version
1 parent a22527a commit 0915260

File tree

9 files changed

+2849
-52
lines changed

9 files changed

+2849
-52
lines changed

Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,13 @@ endif
2222
.PHONY: clean
2323
clean:
2424
( cd ./queue; rm -rf .rocks )
25+
( cd ./crud; rm -rf .rocks )
2526
rm -f $(COVERAGE_FILE)
2627

2728
.PHONY: deps
2829
deps: clean
2930
( cd ./queue/testdata; $(TTCTL) rocks install queue 1.2.1 )
31+
( cd ./crud; $(TTCTL) rocks install crud 0.14.1 )
3032

3133
.PHONY: datetime-timezones
3234
datetime-timezones:
@@ -99,6 +101,13 @@ test-settings:
99101
go clean -testcache
100102
go test -tags "$(TAGS)" ./settings/ -v -p 1
101103

104+
.PHONY: test-crud
105+
test-crud:
106+
@echo "Running tests in crud package"
107+
cd ./crud/ && tarantool -e "require('crud')"
108+
go clean -testcache
109+
go test -tags "$(TAGS)" ./crud/ -v -p 1
110+
102111
.PHONY: test-main
103112
test-main:
104113
@echo "Running tests in main package"

crud/msgpack.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
//go:build !go_tarantool_msgpack_v5
2+
// +build !go_tarantool_msgpack_v5
3+
4+
package crud
5+
6+
import (
7+
"gopkg.in/vmihailenco/msgpack.v2"
8+
)
9+
10+
type encoder = msgpack.Encoder

crud/msgpack_v5.go

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
//go:build go_tarantool_msgpack_v5
2+
// +build go_tarantool_msgpack_v5
3+
4+
package crud
5+
6+
import (
7+
"github.com/vmihailenco/msgpack/v5"
8+
)
9+
10+
type encoder = msgpack.Encoder

0 commit comments

Comments
 (0)