From 87cb21523d06766cade90d888238ec0332825074 Mon Sep 17 00:00:00 2001 From: jand Date: Wed, 27 Aug 2003 20:01:21 +0000 Subject: [PATCH] refined test to find previously undetected bug --- myhdl/test_Signal.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/myhdl/test_Signal.py b/myhdl/test_Signal.py index 7c2f0900..6fb31766 100644 --- a/myhdl/test_Signal.py +++ b/myhdl/test_Signal.py @@ -30,6 +30,7 @@ random.seed(1) # random, but deterministic import sys maxint = sys.maxint import types +import copy import unittest from unittest import TestCase @@ -111,7 +112,10 @@ class SigTest(TestCase): def testUpdate(self): """ _update() should assign next into val """ for s, n in zip(self.sigs, self.nexts): + cur = copy.copy(s.val) s.next = n + # assigning to next should not change current value ... + self.assert_(s.val == cur) s._update() self.assert_(s.val == n)