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

Made a bat for running tests #133

Open
wants to merge 3 commits into
base: development
Choose a base branch
from
Open

Conversation

AlexanderHansson4225
Copy link
Contributor

@AlexanderHansson4225 AlexanderHansson4225 commented May 19, 2023

Important:
Please review, esspecially if you have a windows computer (i dont know who of you have windows, so I just added all of you for review)

Due to me not having a bat compiler (a windows computer), I have not been able to test the bat file. So before you write a comment, please check it thoroughly. Especially:

  1. Can you start a docker container (using -start flag)
  2. Can you restart an existing docker container (same command as 1. - meaning using the -start flag
  3. Can you run the tests (-run flag)
  4. Can you run a specific test class (writting -run <class_name>)

If you receive issues, please tell me (if they are not easy for you to fix) - if you can fix it and you have a bat compiler, please do. Ask if anything is unclear of how to use the script. See -help flag for help <3

If it does not work, and you can not fix it, we can fix it on a thursday on someones windows computer

runTests.bat Outdated
)
docker run -d --name nexpo_database -p 5432:5432 -e POSTGRES_USER=nexpo -e POSTGRES_PASSWORD=nexpo postgres:14
) ELSE IF "%1"=="-run" (
IF "%2"=="" (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't check if the database is running when you don't leave an argument after the -run flag. Is this intentional?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was not intentional, good observation! Thank you, I will fix that

Copy link

@emil-ronkainen emil-ronkainen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The script appears to run as intended on my windows OS!

@AlexanderHansson4225
Copy link
Contributor Author

AlexanderHansson4225 commented May 25, 2023

@S1monG and @emil-ronkainen
Changes have now been made, according to given feedback. I would appreciate a double check once again

@AlexanderHansson4225
Copy link
Contributor Author

Would be great if anyone could check if it works as intended now, after the fix. Thanks in advance

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

Successfully merging this pull request may close these issues.

3 participants