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

Improve automated testing #50

Open
kputnam opened this issue Sep 30, 2020 · 3 comments
Open

Improve automated testing #50

kputnam opened this issue Sep 30, 2020 · 3 comments

Comments

@kputnam
Copy link
Owner

kputnam commented Sep 30, 2020

Since I no longer write PL/pgSQL during the course of my work, it takes me some time to setup a test environment when making changes to this project. Now that Docker is widely used, it makes sense to use it for this purpose. Now that GitHub can execute Docker containers, we can write automated integration tests that talk to an actual PostgreSQL server.

If someone is interested in contributing to this, I'll happily merge a PR. Otherwise, this will be worked on in my spare time.

@kputnam kputnam changed the title Improve automated tests Improve automated testing Sep 30, 2020
@vzdm
Copy link

vzdm commented Jan 19, 2024

I hope to pull piggly into my development environment which is available here.

In this project I am setting up a postgres database which replicates the mssql adventure works database so that as part of feature development the unit tests are automatically executed and coverage reports are generated. I will be adding the functions early in Feb.

My goal is to have piggly installed on the postgres docker image to allow for code coverage reports to be generated. I would be happy to include some test cases to prove out various changes/updates in piggly. You may be able to re-use something from here.

@kputnam
Copy link
Owner Author

kputnam commented Jan 22, 2024

Hi @vzdm, thanks for telling me about your project. Let me know if you need anything, and I'm looking forward to seeing it working!

@vzdm
Copy link

vzdm commented Feb 9, 2024

I've finally managed to get the time to integrate piggly into the project. You can see this in action by running the postgres example, I've updated the readme with details.

For now I have only a single function just to prove out the process and I will add more as time goes on. Not sure why the report is stating 0 coverage but I'll take a look at that later next week. From your perspective this is one way to automatically spin up a postgres instance and test any changes made in piggly.

There is a lot more in my repo you probably don't care about but it's easy to rip out if you decide on re-using anything.

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

No branches or pull requests

2 participants