Mock database connection to test Rex::Commands::DB
Open
Nobody has claimed this yet.
- Dominant language
- Perl
- Stars
- 737
- Forks
- 214
- PR merge metrics
- No merged PRs in 30d
Description
In my opinion it would be nice to avoid pulling in MySQL/MariaDB as a test dependency via Test::mysqld for the Rex::Commands::DB tests in t/db.t. Instead, we could use mocking to provide the test suite with data to work with.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with t/db.t and inspect how the Rex::Commands::DB tests use Test::mysqld and MySQL/MariaDB. Determine how mocked data can cover the existing test cases without a database dependency. Done means the DB tests pass without pulling in MySQL or MariaDB.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- perl
- Domain
- testing
- Issue type
- Refactor
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100