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
2 changes: 1 addition & 1 deletion ruby/lib/ci/queue/build_record.rb
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def record_error(id, payload, stats: nil)
record_stats(stats)
end

def record_success(id, stats: nil, skip_flaky_record: false)
def record_success(id, stats: nil, skip_flaky_record: false, acknowledge: true)
error_reports.delete(id)
record_stats(stats)
end
Expand Down
14 changes: 14 additions & 0 deletions ruby/test/minitest/queue/build_status_recorder_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,20 @@ def test_retrying_test
assert_equal 0, summary.error_reports.size
end

def test_static_queue_record_success
static_queue = CI::Queue::Static.new(['test_example'], CI::Queue::Configuration.new(build_id: '42', worker_id: '1'))
static_reporter = BuildStatusRecorder.new(build: static_queue.build)
static_reporter.start

static_reporter.record(result('test_example'))

assert_equal 1, static_reporter.assertions
assert_equal 0, static_reporter.failures
assert_equal 0, static_reporter.errors
assert_equal 0, static_reporter.skips
assert_equal 0, static_reporter.requeues
end

private

def reserve(queue, method_name)
Expand Down
Loading