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

chore: Boolean Node unit tests #16

Merged
merged 2 commits into from
Jan 1, 2024
Merged

Conversation

barreeeiroo
Copy link
Owner

No description provided.

Copy link

codeclimate bot commented Jan 1, 2024

Code Climate has analyzed commit 06adbe1 and detected 0 issues on this pull request.

View more on Code Climate.

Copy link

sonarqubecloud bot commented Jan 1, 2024

Quality Gate Passed Quality Gate passed

The SonarCloud Quality Gate passed, but some issues were introduced.

4 New issues
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link

@codescene-delta-analysis codescene-delta-analysis bot left a comment

Choose a reason for hiding this comment

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

Code Health Quality Gates: OK

  • Declining Code Health: 1 findings(s) 🚩
  • Improving Code Health: 0 findings(s) ✅
  • Affected Hotspots: 0 files(s) 🔥

Recommended Review Level: Inconclusive -- Not enough commits to recommend a review strategy. The recommendation will be enabled automatically once you have more development activity.
View detailed results in CodeScene

🚩 Declining Code Health (highest to lowest):

Comment on lines +25 to +36
def test_statements(self):
eq1 = LogicEqualNode("a", "b")
eq2 = LogicEqualNode("c", "d")
node = BooleanAndNode(eq1, eq2)

assert node.to_asp(with_comment=True) == [
"% a EQ b",
"eq(mock1) :- s0cc175b9c0f1b6a831c399e269772661 == s92eb5ffee6ae2fec3ad71c777531578f.",
"% c EQ d",
"eq(mock2) :- s4a8a08f09d37b73795649038408b5f33 == s8277e0910d750195b448797616e091ad.",
"and(mock3) :- eq(mock1), eq(mock2).",
]

Choose a reason for hiding this comment

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

❌ New issue: Code Duplication
The module contains 8 functions with similar structure: TestBooleanAndNode.test_hash,TestBooleanAndNode.test_statements,TestBooleanAndNode.test_statements_false,TestBooleanAndNode.test_statements_true and 4 more functions

Why does this problem occur?

Avoid duplicated, aka copy-pasted, code inside the module. More duplication lowers the code health. Read more.

To ignore this warning click here.

Copy link

codecov bot commented Jan 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (630cfd3) 88.72% compared to head (06adbe1) 91.72%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #16      +/-   ##
==========================================
+ Coverage   88.72%   91.72%   +3.00%     
==========================================
  Files          28       28              
  Lines         816      834      +18     
==========================================
+ Hits          724      765      +41     
+ Misses         92       69      -23     

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

@barreeeiroo barreeeiroo merged commit 94f2366 into main Jan 1, 2024
23 of 24 checks passed
@barreeeiroo barreeeiroo deleted the chore/boolean-nodes-unit-tests branch January 1, 2024 01:31
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