Skip to content

Commit

Permalink
Fix: Fix typo in CVE Change EventName enum
Browse files Browse the repository at this point in the history
INITAL_ANALYSIS -> INITIAL_ANALYSIS
  • Loading branch information
bjoernricks authored and greenbonebot committed Nov 17, 2023
1 parent a4df543 commit 0ca44ec
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pontos/nvd/models/cve_change.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

class EventName(StrEnum):
CVE_RECEIVED = "CVE Received"
INITAL_ANALYSIS = "Initial Analysis"
INITIAL_ANALYSIS = "Initial Analysis"
REANALYSIS = "Reanalysis"
CVE_MODIFIED = "CVE Modified"
MODIFIED_ANALYSIS = "Modified Analysis"
Expand Down
4 changes: 2 additions & 2 deletions tests/nvd/cve_changes/test_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ async def test_cve_changes(self):
cve_change = await anext(it)

self.assertEqual(cve_change.cve_id, "CVE-1")
self.assertEqual(cve_change.event_name, EventName.INITAL_ANALYSIS)
self.assertEqual(cve_change.event_name, EventName.INITIAL_ANALYSIS)
self.assertEqual(
cve_change.cve_change_id,
UUID("5160FDEB-0FF0-457B-AA36-0AEDCAB2522E"),
Expand Down Expand Up @@ -179,7 +179,7 @@ async def test_cve_changes_cve_id(self):
async def test_cve_changes_event_name(self):
self.http_client.get.side_effect = create_cve_changes_responses()

it = aiter(self.api.changes(event_name=EventName.INITAL_ANALYSIS))
it = aiter(self.api.changes(event_name=EventName.INITIAL_ANALYSIS))
cve_changes = await anext(it)

self.assertEqual(cve_changes.cve_id, "CVE-1")
Expand Down
4 changes: 2 additions & 2 deletions tests/nvd/models/test_cve_change.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ def test_required_only(self):
class EventNameTestCase(unittest.TestCase):
def test_init(self):
self.assertEqual(
EventName("Initial Analysis"), EventName.INITAL_ANALYSIS
EventName("Initial Analysis"), EventName.INITIAL_ANALYSIS
)

def test__str__(self):
self.assertEqual(str(EventName.INITAL_ANALYSIS), "Initial Analysis")
self.assertEqual(str(EventName.INITIAL_ANALYSIS), "Initial Analysis")

0 comments on commit 0ca44ec

Please sign in to comment.