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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.claude/settings.local.json
6 changes: 6 additions & 0 deletions ruby/lib/ci/queue/grind.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ def from_uri(uri, config)
end
end

# Grind always eagerly loads test files and populates @index via
# Static#populate, so poll uses the @index path. Bypass entry_resolver
# to avoid JSON-formatting overhead on potentially millions of entries.
def entry_resolver; nil; end
def entry_resolver=(_); end

def initialize(path, config)
io = path == '-' ? STDIN : ::File.open(path)

Expand Down
5 changes: 3 additions & 2 deletions ruby/test/ci/queue/redis_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -510,11 +510,12 @@ def test_resolve_entry_falls_back_to_resolver
def test_resolve_entry_returns_unresolved_entry_without_index_or_resolver
queue = worker(1, populate: false)

result = queue.send(:resolve_entry, "MissingTest#test_bar#{DELIMITER}/tmp/missing.rb")
entry = CI::Queue::QueueEntry.format("MissingTest#test_bar", "/tmp/missing.rb")
result = queue.send(:resolve_entry, entry)

assert_instance_of CI::Queue::Redis::UnresolvedEntry, result
assert_equal "MissingTest#test_bar", result.id
assert_equal "MissingTest#test_bar#{DELIMITER}/tmp/missing.rb", result.queue_entry
assert_equal entry, result.queue_entry
end

def test_continuously_timing_out_tests
Expand Down
Loading