Skip to content

Commit

Permalink
unit tests for items.py file
Browse files Browse the repository at this point in the history
  • Loading branch information
mugdhadhole1 committed Oct 11, 2024
1 parent 0c80896 commit c04be9c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions test-system/lobster-python/basic.output
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ Written output for 3 items to basic.lobster
{
"data": [
{
"tag": "python basic.trlc_reference:5",
"tag": "python basic.trlc_reference",
"location": {
"kind": "file",
"file": "basic.py",
"line": 5,
"column": null
},
"name": "basic.trlc_reference:5",
"name": "basic.trlc_reference",
"messages": [],
"just_up": [
"helper function"
Expand Down
8 changes: 4 additions & 4 deletions test-system/lobster-python/pytest_mark.output
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ Written output for 2 items to pytest_mark.lobster
{
"data": [
{
"tag": "pyunit pytest_mark.TestFrameServerProcessesStart.test_1",
"tag": "pyunit pytest_mark.TestFrameServerProcessesStart.test_1:21",
"location": {
"kind": "file",
"file": "pytest_mark.py",
"line": 21,
"column": null
},
"name": "pytest_mark.TestFrameServerProcessesStart.test_1",
"name": "pytest_mark.TestFrameServerProcessesStart.test_1:21",
"messages": [],
"just_up": [],
"just_down": [],
Expand All @@ -23,14 +23,14 @@ Written output for 2 items to pytest_mark.lobster
"status": null
},
{
"tag": "pyunit pytest_mark.TestFrameServerProcessesStart.test_2",
"tag": "pyunit pytest_mark.TestFrameServerProcessesStart.test_2:24",
"location": {
"kind": "file",
"file": "pytest_mark.py",
"line": 24,
"column": null
},
"name": "pytest_mark.TestFrameServerProcessesStart.test_2",
"name": "pytest_mark.TestFrameServerProcessesStart.test_2:24",
"messages": [],
"just_up": [],
"just_down": [],
Expand Down
4 changes: 2 additions & 2 deletions test-unit/test_items.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import unittest
from unittest.mock import patch, MagicMock, create_autospec
from unittest.mock import patch, MagicMock,create_autospec
from lobster.items import Tracing_Tag, Tracing_Status, Item, Requirement, Implementation, Activity
from hashlib import sha1
from lobster.location import Location
Expand All @@ -13,7 +13,7 @@ class SetUp(unittest.TestCase):
mock_text = "mock_text"
mock_status = "active"
mock_language = "mock_language"
mock_location = create_autospec(Location, instance = True)
mock_location = create_autospec(Location, instance=True)
tracing_tag = Tracing_Tag(mock_namespace, mock_tag)
item = Item(tracing_tag, mock_location)
requirement = Requirement(tracing_tag, mock_location, mock_framework, mock_kind, mock_name, mock_text, mock_status)
Expand Down

0 comments on commit c04be9c

Please sign in to comment.