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

pycbc_test_suite to be able to run from anywhere within the git repo #4774

Merged
merged 4 commits into from
Aug 5, 2024

Conversation

GarethCabournDavies
Copy link
Contributor

Add a base directory location - the base directory of the repo - to the pycbc_test_suite bash script, so that it can be run from any directory within the repo.

Motivation

Solve #2639

  • The author of this pull request confirms they will adhere to the code of conduct

@GarethCabournDavies GarethCabournDavies changed the title pycbc_test_suite to be able to run from anywhere within the gt repo pycbc_test_suite to be able to run from anywhere within the git repo Jun 7, 2024
@@ -7,14 +7,18 @@ echo -e "\\n>> [`date`] Python Major Version:" $PYTHON_VERSION
PYTHON_MINOR_VERSION=`python -c 'import sys; print(sys.version_info.minor)'`
echo -e "\\n>> [`date`] Python Minor Version:" $PYTHON_MINOR_VERSION

# This will work from anywhere within the pycbc directory
PYCBC_BASE_DIR=`git rev-parse --show-toplevel`
Copy link
Member

Choose a reason for hiding this comment

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

I think there are problems if we assume git access in certain circumstances (e.g. it will make it hard to integrate into conda's testing if we want to improve that). Can we get this without that?

I think one can do this because the script can know what directly it exists in, no?

Copy link
Member

Choose a reason for hiding this comment

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

I guess a clarification is needed. Do you want to be able to move the test script to any folder or to run the test script from a different folder? I guess my suggestion wouldn't solve the former.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think run from any folder - the git problem raised makes sense, so I will look at that

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think this will work now

@spxiwh spxiwh removed their request for review June 10, 2024 20:48
@GarethCabournDavies
Copy link
Contributor Author

poke on the re-review here

@ahnitz ahnitz enabled auto-merge (squash) August 4, 2024 14:22
@ahnitz
Copy link
Member

ahnitz commented Aug 4, 2024

@GarethCabournDavies You'll just have to rebase to pick up the new required tests.

@ahnitz ahnitz merged commit 1c6ad7e into gwastro:master Aug 5, 2024
30 checks passed
@GarethCabournDavies GarethCabournDavies deleted the test_suite_anydir branch August 5, 2024 09:16
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.

None yet

2 participants