You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
666 B
35 lines
666 B
5 years ago
|
import os
|
||
|
|
||
|
from nose.tools import assert_equal
|
||
|
|
||
|
from panda import Panda, BASEDIR
|
||
|
from .helpers import reset_pandas, test_all_pandas, panda_connect_and_init
|
||
|
|
||
|
|
||
|
# Reset the pandas before flashing them
|
||
|
def aaaa_reset_before_tests():
|
||
|
reset_pandas()
|
||
|
|
||
6 years ago
|
|
||
6 years ago
|
@test_all_pandas
|
||
|
@panda_connect_and_init
|
||
|
def test_recover(p):
|
||
6 years ago
|
assert p.recover(timeout=30)
|
||
|
|
||
5 years ago
|
|
||
6 years ago
|
@test_all_pandas
|
||
|
@panda_connect_and_init
|
||
|
def test_flash(p):
|
||
6 years ago
|
p.flash()
|
||
5 years ago
|
|
||
|
|
||
|
@test_all_pandas
|
||
|
@panda_connect_and_init
|
||
|
def test_get_signature(p):
|
||
|
fn = os.path.join(BASEDIR, "board/obj/panda.bin")
|
||
|
|
||
|
firmware_sig = Panda.get_signature_from_firmware(fn)
|
||
|
panda_sig = p.get_signature()
|
||
|
|
||
|
assert_equal(panda_sig, firmware_sig)
|