-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f642745
commit b90c174
Showing
4 changed files
with
25 additions
and
0 deletions.
There are no files selected for viewing
Binary file not shown.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import unittest | ||
|
||
class RfCatBasicTests(unittest.TestCase): | ||
|
||
def test_importing(self): | ||
import rflib | ||
devs = rflib.getRfCatDevices() | ||
self.assertEquals(type(devs), list, "rflib.getRfCatDevices() doesn't return a list!: %r" % devs) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import os | ||
import unittest | ||
|
||
import PE | ||
import vivisect.tests.helpers as helpers | ||
|
||
class RfCatBasicTests(unittest.TestCase): | ||
|
||
def test_export_by_name(self): | ||
file_path = helpers.getTestPath('windows', 'i386', 'export_by_name.dll') | ||
pe = PE.peFromFileName(file_path) | ||
export_list = pe.getExports() | ||
self.assertEquals(len(export_list), 2, "expecting 2 exported functions") | ||
self.assertEquals(export_list[0][1], 0, "exported function with ordinal 0 not found") | ||
self.assertEquals(export_list[0][2], "Func1", "exported function with name 'Func1' not found") | ||
|