Skip to content

Commit

Permalink
tarantool
Browse files Browse the repository at this point in the history
  • Loading branch information
oleg-jukovec committed Apr 8, 2024
1 parent 5830f09 commit 12ef910
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 7 deletions.
45 changes: 41 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,19 +28,56 @@ jobs:
cartridge: true
coveralls: true
metrics: true
- tarantool: 'master'
cartridge: false
coveralls: false
metrics: false

runs-on: ubuntu-20.04
steps:
- name: Clone the module
uses: actions/checkout@v3

- name: Setup tt
run: |
curl -L https://tarantool.io/release/2/installer.sh | sudo bash
sudo apt install -y tt
- name: Install tarantool ${{ matrix.tarantool }}
uses: tarantool/setup-tarantool@v2
uses: tarantool/setup-tarantool@v3
with:
tarantool-version: ${{ matrix.tarantool }}
if: matrix.tarantool != 'master'

- name: Clone the module
uses: actions/checkout@v3
- name: Get Tarantool master latest commit
if: matrix.tarantool == 'master'
run: |
commit_hash=$(git ls-remote https://github.com/tarantool/tarantool.git --branch master | head -c 8)
echo "LATEST_COMMIT=${commit_hash}" >> $GITHUB_ENV
shell: bash

- name: Cache Tarantool master
if: matrix.tarantool == 'master'
id: cache-latest
uses: actions/cache@v3
with:
path: "${GITHUB_WORKSPACE}/bin"
key: cache-latest-${{ env.LATEST_COMMIT }}

- name: Setup Tarantool CE (master)
if: matrix.tarantool == 'master' && steps.cache-latest.outputs.cache-hit != 'true'
run: |
tt init
tt install tarantool master
- name: Add tt Tarantool to PATH
if: matrix.tarantool == 'master'
run: echo "${GITHUB_WORKSPACE}/bin" >> $GITHUB_PATH

- name: Install requirements
run: make deps
run: |
tarantool --version
make deps
- name: Install Cartridge requirements
run: make deps-cartridge
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ build:

.PHONY: deps
deps:
$(TTCTL) rocks install vshard 0.1.18
$(TTCTL) rocks install vshard 0.1.25
$(TTCTL) rocks install luacheck 0.26.0
$(TTCTL) rocks install luacov 0.13.0
$(TTCTL) rocks install luacov-coveralls 0.2.3-1 --server=http://luarocks.org
Expand Down
2 changes: 1 addition & 1 deletion sharded-queue-scm-1.rockspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ source = {
}
dependencies = {
'lua >= 5.1',
'vshard >= 0.1.18-1',
'vshard >= 0.1.25-1',
}

external_dependencies = {
Expand Down
2 changes: 1 addition & 1 deletion test/api_test.lua
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
local t = require('luatest')
local g = t.group('api')

local api = require('sharded_queue.api')
local _, api = pcall(require, 'sharded_queue.api')
local helper = require('test.helper')
local utils = require('test.helper.utils')
local tube = require('sharded_queue.router.tube')
Expand Down

0 comments on commit 12ef910

Please sign in to comment.