tryouts 3.5.2 → 3.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 958254585920c850e17a18e13699040fad97ec8610f3c2141b32899016dc4194
4
- data.tar.gz: 3666350beb13d17cf24bf184350fd88746cebbf7b7efc109c3e5af7f8d5c6c3b
3
+ metadata.gz: 3abd83819eeaeaaa533ccf639c975c295737c0241aaded166bda76e95ae0f127
4
+ data.tar.gz: 0f75679e487a62ef5be88d75c66f6c508efa7ce0867a42354a9e99aac1ea6142
5
5
  SHA512:
6
- metadata.gz: 1a1091a28256b97c210f8a0a970db3a78d715e1b195e95a5a844e8f32b7d65f7e6d5cb49209baaf2c061b02500ad6bf2d71968cbcb76c16206108eabfa8039f3
7
- data.tar.gz: 9613b25213146c5da6dbd5153fa101e8139e205f06fb5bcddb8fa172a82fc76dffff56f79d69609c4764623ac9bf0682a0ba8ef4e76fd49517920a9b3e1141af
6
+ metadata.gz: 7f389b6b637cb53cfeb7bd9d20ecd4e8d1392329ec1ec89b390d1f2eb2e0f43c2fda1d503422819b7694d13d867f81b0fa2a0bf644ab60f75004fc8ce92376ab
7
+ data.tar.gz: 0f72eef3666c7391e4cdfafa6f619878d04a685f7b77d6339de6f757940649b6c0e54f8581738592941f92beab11001b185da4869382544803c51d4acac5bdf1
@@ -284,10 +284,6 @@ class Tryouts
284
284
  " (#{@total_stats[:elapsed_time].round(2)}s)"
285
285
  end
286
286
 
287
- # Add execution context header for agent clarity
288
- output << render_execution_context
289
- output << ""
290
-
291
287
  # Count failures manually from collected file data (same as other render methods)
292
288
  failed_count = @collected_files.sum { |f| f[:failures].size }
293
289
  error_count = @collected_files.sum { |f| f[:errors].size }
@@ -299,7 +295,9 @@ class Tryouts
299
295
  details = []
300
296
  details << "#{failed_count} failed" if failed_count > 0
301
297
  details << "#{error_count} errors" if error_count > 0
302
- status_parts << "FAIL: #{issues_count}/#{@total_stats[:tests]} tests (#{details.join(', ')}, #{passed_count} passed#{time_str})"
298
+ summary = "#{passed_count} testcases passed, #{failed_count} failed"
299
+ summary += ", #{error_count} errors" if error_count > 0
300
+ status_parts << "SUMMARY: #{summary}#{time_str}"
303
301
  else
304
302
  # Agent doesn't need output in the positive case (i.e. for passing
305
303
  # tests). It just fills out the context window.
@@ -314,14 +312,14 @@ class Tryouts
314
312
 
315
313
  files_with_issues = @collected_files.select { |f| f[:failures].any? || f[:errors].any? }
316
314
  if files_with_issues.any?
317
- output << "Files:"
315
+ output << "FILES:"
318
316
  files_with_issues.each do |file_data|
319
317
  issue_count = file_data[:failures].size + file_data[:errors].size
320
318
  output << " #{file_data[:path]}: #{issue_count} issue#{'s' if issue_count != 1}"
321
319
  end
322
320
  elsif @collected_files.any?
323
321
  # Show files that were processed successfully
324
- output << "Files:"
322
+ output << "FILES:"
325
323
  @collected_files.each do |file_data|
326
324
  # Use the passed count from file_result if available, otherwise calculate
327
325
  passed_tests = file_data[:passed] ||
@@ -330,6 +328,10 @@ class Tryouts
330
328
  end
331
329
  end
332
330
 
331
+ # Add execution context at the end
332
+ output << ""
333
+ output << render_execution_context
334
+
333
335
  puts output.join("\n") if output.any?
334
336
  end
335
337
 
@@ -345,19 +347,21 @@ class Tryouts
345
347
 
346
348
  output = []
347
349
 
348
- # Add execution context header for agent clarity
349
- output << render_execution_context
350
- output << ""
351
-
352
350
  if critical_files.empty?
353
351
  output << "No critical errors found"
352
+ # Add execution context at the end
353
+ output << ""
354
+ output << render_execution_context
354
355
  puts output.join("\n")
355
356
  return
356
357
  end
357
358
 
358
- output << "CRITICAL: #{critical_files.size} file#{'s' if critical_files.size != 1} with errors#{time_str}"
359
+ # Summary first
360
+ output << "SUMMARY:"
361
+ output << "#{critical_files.size} file#{'s' if critical_files.size != 1} with critical errors#{time_str}"
359
362
  output << ""
360
363
 
364
+ # Error details
361
365
  critical_files.each do |file_data|
362
366
  unless @budget.has_budget?
363
367
  output << "... (truncated due to token limit)"
@@ -379,6 +383,9 @@ class Tryouts
379
383
  output << ""
380
384
  end
381
385
 
386
+ # Add execution context at the end
387
+ output << render_execution_context
388
+
382
389
  puts output.join("\n")
383
390
  end
384
391
 
@@ -391,16 +398,20 @@ class Tryouts
391
398
  " (#{@total_stats[:elapsed_time].round(2)}s)"
392
399
  end
393
400
 
394
- # Add execution context header for agent clarity
395
- output << render_execution_context
396
- output << ""
397
-
398
401
  # Count actual failures from collected data
399
402
  failed_count = @collected_files.sum { |f| f[:failures].size }
400
403
  error_count = @collected_files.sum { |f| f[:errors].size }
401
404
  issues_count = failed_count + error_count
402
405
  passed_count = [@total_stats[:tests] - issues_count, 0].max
403
406
 
407
+ # Summary first
408
+ output << "SUMMARY:"
409
+ summary = "#{passed_count} testcases passed, #{failed_count} failed"
410
+ summary += ", #{error_count} errors" if error_count > 0
411
+ summary += " in #{@total_stats[:files]} files#{time_str}"
412
+ output << summary
413
+ output << ""
414
+
404
415
  # Show files with issues only
405
416
  files_with_issues = @collected_files.select { |f| f[:failures].any? || f[:errors].any? }
406
417
 
@@ -422,13 +433,8 @@ class Tryouts
422
433
  output << ""
423
434
  end
424
435
 
425
- # Final summary line
426
- summary = "Summary: \n"
427
- summary += "#{passed_count} testcases passed, #{failed_count} failed"
428
- summary += ", #{error_count} errors" if error_count > 0
429
- summary += " in #{@total_stats[:files]} files#{time_str}"
430
-
431
- output << summary
436
+ # Add execution context at the end
437
+ output << render_execution_context
432
438
 
433
439
  puts output.join("\n")
434
440
  end
@@ -553,7 +559,7 @@ class Tryouts
553
559
 
554
560
  def render_execution_context
555
561
  context_lines = []
556
- context_lines << "EXECUTION_CONTEXT:"
562
+ context_lines << "CONTEXT:"
557
563
 
558
564
  # Command that was executed
559
565
  if @options[:original_command]
@@ -1,5 +1,5 @@
1
1
  # lib/tryouts/version.rb
2
2
 
3
3
  class Tryouts
4
- VERSION = '3.5.2'
4
+ VERSION = '3.6.0'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tryouts
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.5.2
4
+ version: 3.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Delano Mandelbaum