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

pgtap directory & file names #118

Open
cvvergara opened this issue Jul 31, 2020 · 0 comments
Open

pgtap directory & file names #118

cvvergara opened this issue Jul 31, 2020 · 0 comments
Labels

Comments

@cvvergara
Copy link
Member

The structure is getting obsolete as in the directories there are many functions within a directory also file names using dash instead of underscore.

directory structure

Current structure

pgtap/theLongNameDir/

which makes the need to have as prefix the name of the function on the test files for example :

ls pgtap/theLongNameDir/
theVeryLongNameBarFunction_edge_cases.sql
...
theVeryLongNameFooFunction_edge_cases.sql
...

The "not yet written" to be standard about the directory structure

Subdivide the directory with the functions and the need of prefixing the file names is gone as the prefix is on the subdirectory name

pgtap/theLongNameDir/function

Following the example above:
the directory pgtap/theLongNameDir would have 2 subdirectories:

ls pgtap/theLongNameDir/
theVeryLongNameBarFunction
theVeryLongNameFooFunction

So the files mentioned in the example:

pgtap/theLongNameDir/theVeryLongNameFooFunction/edge_cases.sql
pgtap/theLongNameDir/theVeryLongNameBarFunction/edge_cases.sql

File names

If a files use dash to separate words for example:

edge-cases.sql

The dash sometimes generates problems when using scripts as the options for commands use a dash.
To avoid those problems, use an underscore:

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

No branches or pull requests

1 participant