Skip to content

Commit dc62f74

Browse files
authored
Fixing the min required version for Crystal. Disable init_env spec when running on Crystal < 1.16 (#40)
1 parent d83d7e3 commit dc62f74

File tree

3 files changed

+7
-4
lines changed

3 files changed

+7
-4
lines changed

.github/workflows/ci.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,11 @@ jobs:
1414
continue-on-error: false
1515
steps:
1616
- name: Download source
17-
uses: actions/checkout@v3
17+
uses: actions/checkout@v4
1818
- name: Install Crystal
1919
uses: crystal-lang/install-crystal@v1
20+
with:
21+
crystal: latest
2022
- name: Install shards
2123
run: shards install
2224
- name: Format
@@ -31,11 +33,11 @@ jobs:
3133
crystal_version: [latest]
3234
include:
3335
- os: ubuntu-latest
34-
crystal_version: 1.4.0
36+
crystal_version: 1.10.0
3537
runs-on: ${{ matrix.os }}
3638
continue-on-error: false
3739
steps:
38-
- uses: actions/checkout@v3
40+
- uses: actions/checkout@v4
3941
- uses: crystal-lang/install-crystal@v1
4042
with:
4143
crystal: ${{ matrix.crystal_version }}

shard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ version: 0.2.0
44
authors:
55
- Jeremy Woertink <jeremywoertink@gmail.com>
66

7-
crystal: ">= 1.4.0"
7+
crystal: ">= 1.10.0"
88

99
license: MIT
1010

spec/init_env_spec.cr

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
{% skip_file if compare_versions(Crystal::VERSION, "1.16.0") < 0 %}
12
require "./spec_helper"
23

34
# Must be called up here, otherwise crystal throws "Error: can't declare def dynamically" error

0 commit comments

Comments
 (0)