Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
continue-on-error: false
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: crystal-lang/install-crystal@v1
with:
crystal: latest
Expand All @@ -29,11 +29,12 @@ jobs:
matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest
shard_file:
- shard.yml
crystal_version:
- 1.15.1
- 1.16.3
- latest
experimental:
- false
Expand All @@ -49,7 +50,7 @@ jobs:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ matrix.experimental }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
- uses: crystal-lang/install-crystal@v1
with:
crystal: ${{matrix.crystal_version}}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ name: Deploy docs

on:
push:
branches: [ main ]
branches: [main]

jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v6
with:
persist-credentials: false
- uses: crystal-lang/install-crystal@v1
Expand Down
2 changes: 1 addition & 1 deletion shard.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: lucky
version: 1.4.0

crystal: ">= 1.15.1"
crystal: ">= 1.16.3"

authors:
- Paul Smith <paulcsmith0218@gmail.com>
Expand Down
4 changes: 2 additions & 2 deletions spec/lucky/format_edge_cases_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -245,9 +245,9 @@ describe "Format Detection Edge Cases" do
long_path = "/very/long/path/" + ("segment/" * 1000) + "file.json"

# Should still extract format efficiently
start_time = Time.monotonic
start_time = {% if compare_versions(Crystal::VERSION, "1.19.0") < 0 %}Time.monotonic{% else %}Time.instant{% end %}
format = Lucky::MimeType.extract_format_from_path(long_path)
end_time = Time.monotonic
end_time = {% if compare_versions(Crystal::VERSION, "1.19.0") < 0 %}Time.monotonic{% else %}Time.instant{% end %}

format.should eq Lucky::Format::Json
(end_time - start_time).should be < 0.1.seconds # Should be very fast
Expand Down