Skip to content

Integration test suite: Ruby errors are not detected #7509

@WolfgangHG

Description

@WolfgangHG

See e.g. https://github.com/microsoft/kiota/actions/runs/23022145076/job/66971518173?pr=7414#step:17:230

The test "integration (ruby, apisguru::twitter.com:current)" fails with a compilation error:

SyntaxError:
  --> /home/runner/work/kiota/kiota/it/ruby/lib/integration_test/client/models/rules_request_summary.rb
  syntax error, unexpected `end', expecting `when'
     5  module Integration_test
     6      module Client
     7          module Models
    10              class RulesRequestSummary
    23                  def self.create_from_discriminator_value(parse_node)
    26                      unless mapping_value_node.nil? then
  > 27                          mapping_value = mapping_value_node.get_string_value
  > 28                          case mapping_value
  > 29                          end
    30                      end
    32                  end
    83              end
    84          end
    85      end
    86  end
  
  /home/runner/work/kiota/kiota/it/ruby/lib/integration_test/client/models/rules_request_summary.rb:29: syntax error, unexpected `end', expecting `when' (SyntaxError)
                          end
                          ^~~

But the Github CI test is green.

Probably caused because the ruby call in "exec-cmd.ps1" lacks the "-ErrorAction=Stop" parameter:

kiota/it/exec-cmd.ps1

Lines 168 to 172 in 6a0acc6

Invoke-call -ScriptBlock {
git init
bundle install
bundle exec rake
}

Easy to fix, but someone would have to take fix the code generation errors - and I don't have any idea of ruby.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Status

    Needs Triage 🔍

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions