Sha256: ed66e3c2b5a6165e97314ae628ad88a5eef1325d8afdc43adcacf3d8a12a326e

Contents?: true

Size: 424 Bytes

Versions: 77

Compression:

Stored size: 424 Bytes

Contents

require "spec_helper"

describe GitLab::Exporter::TimeTracker do
  it "tracks execution time" do
    expect(subject.track { sleep 0.1 }.time).to satisfy { |v| v >= 0.1 }
  end
end

describe GitLab::Exporter::Utils do
  it "excludes extraneous PIDs" do
    allow(described_class).to receive(:exec_pgrep).and_return("12345 my-process\n98765 sh\n")

    expect(described_class.pgrep("some-process")).to eq(["12345"])
  end
end

Version data entries

77 entries across 77 versions & 1 rubygems

Version Path
gitlab-exporter-12.0.1 spec/util_spec.rb
gitlab-exporter-12.0.0 spec/util_spec.rb
gitlab-exporter-11.19.0 spec/util_spec.rb
gitlab-exporter-11.18.2 spec/util_spec.rb
gitlab-exporter-11.18.1 spec/util_spec.rb
gitlab-exporter-11.18.0 spec/util_spec.rb
gitlab-exporter-11.17.1 spec/util_spec.rb
gitlab-exporter-11.17.0 spec/util_spec.rb
gitlab-exporter-11.16.0 spec/util_spec.rb
gitlab-exporter-11.15.2 spec/util_spec.rb
gitlab-exporter-11.15.1 spec/util_spec.rb
gitlab-exporter-11.15.0 spec/util_spec.rb
gitlab-exporter-11.14.0 spec/util_spec.rb
gitlab-exporter-11.13.1 spec/util_spec.rb
gitlab-exporter-11.13.0 spec/util_spec.rb
gitlab-exporter-11.12.0 spec/util_spec.rb
gitlab-exporter-11.11.0 spec/util_spec.rb
gitlab-exporter-11.10.0 spec/util_spec.rb
gitlab-exporter-11.9.0 spec/util_spec.rb
gitlab-exporter-11.8.0 spec/util_spec.rb