mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
spec/ruby/core/process/clock_getres_spec.rb: lax the resolution limit
Android is Linux, but the clock resolution is 10 milliseconds. I think that 1 microsecond is too strict for embedded environment. This change laxes the limit to 10 milliseconds.
This commit is contained in:
parent
fe2a832ace
commit
224f29c8e9
1 changed files with 4 additions and 4 deletions
|
@ -20,14 +20,14 @@ describe "Process.clock_getres" do
|
||||||
# These are observed
|
# These are observed
|
||||||
|
|
||||||
platform_is :linux, :darwin, :windows do
|
platform_is :linux, :darwin, :windows do
|
||||||
it "with Process::CLOCK_REALTIME reports at least 1 microsecond" do
|
it "with Process::CLOCK_REALTIME reports at least 10 millisecond" do
|
||||||
Process.clock_getres(Process::CLOCK_REALTIME, :nanosecond).should <= 1_000
|
Process.clock_getres(Process::CLOCK_REALTIME, :nanosecond).should <= 10_000_000
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
platform_is :linux, :darwin, :windows do
|
platform_is :linux, :darwin, :windows do
|
||||||
it "with Process::CLOCK_MONOTONIC reports at least 1 microsecond" do
|
it "with Process::CLOCK_MONOTONIC reports at least 10 millisecond" do
|
||||||
Process.clock_getres(Process::CLOCK_MONOTONIC, :nanosecond).should <= 1_000
|
Process.clock_getres(Process::CLOCK_MONOTONIC, :nanosecond).should <= 10_000_000
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Add table
Reference in a new issue