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

Refactored base64 attachment handling #1191

Merged
merged 3 commits into from
Aug 27, 2024

Conversation

caronc
Copy link
Owner

@caronc caronc commented Aug 27, 2024

Description:

Related issue (if applicable): n/a

Refactored the way base64 attachments are generated. removed duplicated code and provided a consistent solution for all attachment types.

Checklist

  • The code change is tested and works locally.
  • There is no commented out code in this PR.
  • No lint errors (use flake8)
  • 100% test coverage

Testing

Anyone can help test this source code as follows:

# Create a virtual environment to work in as follows:
python3 -m venv apprise

# Change into our new directory
cd apprise

# Activate our virtual environment
source bin/activate

# Install the branch
pip install git+https://github.com/caronc/apprise.git@base64-encoding-attachment-refactoring

# Test out the changes with the following command:
apprise -t "Test Title" -b "Test Message" \
  syntax://credentials --attach=/path/to/attachment

Copy link

codecov bot commented Aug 27, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.35%. Comparing base (ca50cb7) to head (cda1bd9).
Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1191   +/-   ##
=======================================
  Coverage   99.35%   99.35%           
=======================================
  Files         146      146           
  Lines       20213    20219    +6     
  Branches     3972     3966    -6     
=======================================
+ Hits        20082    20088    +6     
  Misses        121      121           
  Partials       10       10           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@caronc caronc merged commit 98fb486 into master Aug 27, 2024
14 checks passed
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.

1 participant