Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ruby-plugin: initial set of test cases #2345

Merged
merged 5 commits into from Feb 2, 2019

Conversation

BernhardDenner
Copy link
Collaborator

Added some basic test cases for

  • plugin loading
  • getting a keySet with kdbGet
  • passing a keySet with kdbSet

Basics

Do not describe the purpose here but:

  • Short descriptions should be in the release notes (added as entry in
    doc/news/_preparation_next_release.md which contains *(my name)*)
    Please always add something to the the release notes.
  • Longer descriptions should be in documentation or in design decisions.
  • Describe details of how you changed the code in commit messages
    (first line should have module: short statement syntax)
  • References to issues, e.g. close #X, should be in the commit messages.

Checklist

Check relevant points but please do not remove entries.
For docu fixes, spell checking, and similar none of these points below
need to be checked.

  • I added unit tests
  • I ran all tests locally and everything went fine
  • affected documentation is fixed
  • I added code comments, logging, and assertions (see doc/CODING.md)
  • meta data is updated (e.g. README.md of plugins)

@markus2330 please review my pull request

@markus2330
Copy link
Contributor

Thank you for working on this!

@sanssecours do you know why coveralls failed? And how to rebuild it?

@sanssecours
Copy link
Member

do you know why coveralls failed?

If you mean for this pull request, then the coverage report of 2.2 % is a result of the termination of the main build job debian-stable-full.

And how to rebuild it?

Since the coverage report is tied to the main build job, executing debian-stable-full again should be enough. The result (failure, since the coverage is below 60%) will probably the same though, until the build job runs successfully.

@BernhardDenner
Copy link
Collaborator Author

I have no idea why testmod_ruby is failing during the test run after make install. During the first test run everything is working but then the tests are not able to load the Ruby bindings (LoadError). The RUBYLIB env var is still set correctly (is it?) however the bindings module (kdb) is not found.

Does anybody know what is happening here?

@markus2330
Copy link
Contributor

markus2330 commented Jan 29, 2019

Is the Ruby binding installed at the correct place during make install? (On my system it is /usr/local/lib/site_ruby but other packages install their Ruby bindings to /usr/lib/x86_64-linux-gnu/ruby/vendor_ruby/2.3.0/) If installed at the default location, RUBYLIB should not be needed at all.

Added some basic test cases for
* plugin loading
* getting a keySet with kdbGet
* passing a keySet with kdbSet
This is required to have the test scripts find the Ruby bindings
@BernhardDenner
Copy link
Collaborator Author

Oh man ... I think it was already too late for figuring this out (honestly, I was sitting in a bar having my second drink while working on that :P ).

The test case didn't find the ruby test scripts not the ruby bindings and this was a result of a misconfigured install path.

@markus2330 markus2330 merged commit 5a8e59d into ElektraInitiative:master Feb 2, 2019
@markus2330
Copy link
Contributor

Many thanks! Could you please have a look at #2351?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants