Skip to content

Commit

Permalink
Update to OpenRiak
Browse files Browse the repository at this point in the history
... and simple changes for OTP 26 compatibility
  • Loading branch information
martinsumner committed Sep 26, 2024
1 parent 6361b71 commit 7c5fef1
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 16 deletions.
29 changes: 17 additions & 12 deletions .github/workflows/erlang.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,36 @@ name: Erlang CI

on:
push:
branches: [ develop ]
branches:
- nhse-develop
- nhse-develop-3.2
- nhse-develop-3.4
pull_request:
branches: [ develop ]

branches:
- nhse-develop
- nhse-develop-3.2
- nhse-develop-3.4

jobs:

build:

runs-on: ubuntu-latest
name: Test on ${{ matrix.os }} with OTP ${{ matrix.otp }}
runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
otp:
- "25.1"
- "24.3"
- "22.3"

container:
image: erlang:${{ matrix.otp }}
otp: [24, 26]
os: [ubuntu-latest]

steps:
- uses: lukka/get-cmake@latest
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Install Erlang/OTP
uses: erlef/setup-beam@v1
with:
otp-version: ${{ matrix.otp }}
- name: Compile
run: ./rebar3 compile
- name: Run xref and dialyzer
Expand Down
2 changes: 1 addition & 1 deletion rebar.config
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
deprecated_function_calls,
deprecated_functions]}.
{cover_enabled, true}.
{deps, [{basho_stats, ".*", {git, "https://github.com/nhs-riak/basho_stats.git", {branch, "nhse-develop"}}}]}.
{deps, [{basho_stats, ".*", {git, "https://github.com/OpenRiak/basho_stats.git", {branch, "nhse-develop"}}}]}.

{profiles, [
{test, [{deps, [{proper, ".*", {git, "https://github.com/proper-testing/proper.git", {tag, "v1.4"}}}]}]},
Expand Down
1 change: 1 addition & 0 deletions src/hyper.app.src
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@
kernel,
stdlib
]},
{included_applications, [basho_stats]},
{env, []}
]}.
3 changes: 2 additions & 1 deletion src/hyper_binary.erl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
%% inserts to perform in the future.

-module(hyper_binary).
-include_lib("eunit/include/eunit.hrl").
-behaviour(hyper_register).
%%-compile(native).

Expand Down Expand Up @@ -276,6 +275,8 @@ merge_buf(B, [{Index, Value} | Rest], PrevIndex, Acc) ->

-ifdef(TEST).

-include_lib("eunit/include/eunit.hrl").

merge_test() ->
P = 4, M = m(P),
Tmp1 = [{1, 1},
Expand Down
3 changes: 2 additions & 1 deletion src/hyper_binary_rle.erl
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
-module(hyper_binary_rle).
-include_lib("eunit/include/eunit.hrl").

-export([new/1, set/3, compact/1, max_merge/1, max_merge/2,
reduce_precision/2, bytes/1]).
Expand Down Expand Up @@ -200,6 +199,8 @@ take_repeat(<<Repeats:?REPEAT, Value:?VALUE, Rest/binary>>) ->
%%
-ifdef(TEST).

-include_lib("eunit/include/eunit.hrl").

format({rle, <<?MARKER, B/binary>>}) ->
rle_to_list(B).

Expand Down
3 changes: 2 additions & 1 deletion src/hyper_gb.erl
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
-module(hyper_gb).
-include_lib("eunit/include/eunit.hrl").

-behaviour(hyper_register).
-export([new/1,
Expand Down Expand Up @@ -131,6 +130,8 @@ do_decode_registers(<<Value:8/integer, Rest/binary>>, I) ->
%%
-ifdef(TEST).

-include_lib("eunit/include/eunit.hrl").

sum_test() ->
T = set(3, 5, set(1, 1, new(4))),

Expand Down

0 comments on commit 7c5fef1

Please sign in to comment.