Skip to content

Commit

Permalink
enable spec
Browse files Browse the repository at this point in the history
  • Loading branch information
HertzDevil committed Sep 27, 2024
1 parent dc7320d commit 3a02830
Showing 1 changed file with 9 additions and 14 deletions.
23 changes: 9 additions & 14 deletions spec/std/kernel_spec.cr
Original file line number Diff line number Diff line change
Expand Up @@ -254,27 +254,22 @@ describe "hardware exception" do
error.should_not contain("Stack overflow")
end

{% if flag?(:musl) %}
# FIXME: Pending as mitigation for https://github.com/crystal-lang/crystal/issues/7482
pending "detects stack overflow on the main stack"
{% else %}
it "detects stack overflow on the main stack", tags: %w[slow] do
# This spec can take some time under FreeBSD where
# the default stack size is 0.5G. Setting a
# smaller stack size with `ulimit -s 8192`
# will address this.
status, _, error = compile_and_run_source <<-'CRYSTAL'
it "detects stack overflow on the main stack", tags: %w[slow] do
# This spec can take some time under FreeBSD where
# the default stack size is 0.5G. Setting a
# smaller stack size with `ulimit -s 8192`
# will address this.
status, _, error = compile_and_run_source <<-'CRYSTAL'
def foo
y = StaticArray(Int8, 512).new(0)
foo
end
foo
CRYSTAL

status.success?.should be_false
error.should contain("Stack overflow")
end
{% end %}
status.success?.should be_false
error.should contain("Stack overflow")
end

it "detects stack overflow on a fiber stack", tags: %w[slow] do
status, _, error = compile_and_run_source <<-'CRYSTAL'
Expand Down

0 comments on commit 3a02830

Please sign in to comment.