Skip to content

Commit 61fd916

Browse files
committed
resolve merge conflict in README
2 parents 4645390 + 2e43e43 commit 61fd916

File tree

7 files changed

+437
-0
lines changed

7 files changed

+437
-0
lines changed

README.md

+36
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,42 @@ or
6868
This can be done in one go in an isolated environment. Just run `tox`.
6969
Add `-p auto` to parallelize for all test-environments, `-e py<yourversion>` to only test against a single version of python.
7070

71+
- Do not merge user-visible changes without documenting them in the changelog. Also create/request a release from the
72+
old version if it does not exist yet.
73+
74+
- Before merging a pull-request, make sure that at least one other person has reviewed or at least
75+
sanity checked the changes.
76+
77+
- Please use meaningful commit-messages, describe what and if necessary how you changed things. Not just "Fixed Stuff".
78+
79+
- When opening a pull request, please make sure all changes are self-contained and complete. In case you made some
80+
incidental fixes put them in a separate branch
81+
(e.g. by cherry-picking/ interactive rebasing the desired changes onto new branches.
82+
83+
- Unless traffic in this repo increases dramatically, you don't squash changes before merging.
84+
Merged branches can be deleted
85+
86+
### Codestyle
87+
88+
- Style follows PEP8, with the exception of line-length of 120 characters
89+
90+
- Docstrings, especially for functions, follow to the numpy guidelines.
91+
92+
- Prefer meaningful variable names over abbreviations. E.g. `magnitude, flux, flux_error` over `m, f, df` unless
93+
its very clear from context (`for i in range(...):`) or established notation.
94+
95+
- Write at least basic smoke-tests (i.e. "if I run this, does it explode right away?") for new functionality and when
96+
refactoring existing code.
97+
98+
## Changelog
99+
100+
###v1.0
101+
Initial release
102+
103+
### unreleased Changes
104+
105+
- (example) Testdata available as package resources: `mascado.resources.example_files`
106+
71107
## License
72108

73109
Copyright 2018 Hannes Riechert <[email protected]>

mascado/resources/__init__.py

Whitespace-only changes.

mascado/resources/example_input/__init__.py

Whitespace-only changes.

mascado/resources/example_input/affine_example.txt

+192
Large diffs are not rendered by default.

mascado/resources/example_input/distorted_example.txt

+192
Large diffs are not rendered by default.

setup.py

+1
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,6 @@
2323
scripts=[
2424
'scripts/mascado_analyze',
2525
'scripts/mascado_compare'],
26+
package_data={'mascado': ['resources/example_input/*']},
2627
test_suite='tests',
2728
)

tests/test_access_resources.py

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
from importlib.resources import read_text, contents, files
2+
from unittest import TestCase
3+
import mascado.resources as res
4+
5+
6+
class TestAccess (TestCase):
7+
def test_examples(self):
8+
affine_example = 'affine_example.txt'
9+
distorted_example = 'distorted_example.txt'
10+
resource_names = list(contents('mascado.resources.example_input'))
11+
12+
assert affine_example in resource_names
13+
assert distorted_example in resource_names
14+
15+
assert read_text('mascado.resources.example_input', affine_example)
16+
assert read_text('mascado.resources.example_input', distorted_example)

0 commit comments

Comments
 (0)