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

Add basic tests for mdatp #3511

Draft
wants to merge 3 commits into
base: main
Choose a base branch
from
Draft
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
flake8 errors fixed in the new files added in this PR
  • Loading branch information
atbagga committed Nov 13, 2024
commit 484f6f3b42b265d9d819ac2b34efe4c852c65e55
1 change: 0 additions & 1 deletion microsoft/testsuites/mdatp/mdatp_basic.py
Original file line number Diff line number Diff line change
@@ -17,7 +17,6 @@
from lisa.testsuite import TestResult
from lisa.tools import Curl
from lisa.util import LisaException, SkippedException

from microsoft.testsuites.mdatp.mdatp_tools import Mdatp


5 changes: 3 additions & 2 deletions microsoft/testsuites/mdatp/mdatp_tools.py
Original file line number Diff line number Diff line change
@@ -3,9 +3,10 @@
import json
from typing import Any

from lisa.tools import Chmod
from lisa.base_tools import Wget
from lisa.executable import Tool
from lisa.tools import Chmod


class Mdatp(Tool):
@property
@@ -90,4 +91,4 @@ def get_result(
result.assert_exit_code(include_output=True)
Copy link
Member

Choose a reason for hiding this comment

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

Add error message for assertion, so the test case can bring more information, when it's failed.

if json_out:
return json.loads(result.stdout)
return result.stdout.split()
return result.stdout.split()
Loading
Oops, something went wrong.