forked from buildbot/buildbot
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sure that SourceStamp.revision=None is not 'None' when using the
latest change's revision to calculate the SourceStamp's revision Fixes: buildbot#864
- Loading branch information
Chris AtLee
committed
Jun 22, 2010
1 parent
a9fcc09
commit 6e717ac
Showing
2 changed files
with
18 additions
and
5 deletions.
There are no files selected for viewing
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
11 changes: 11 additions & 0 deletions
11
master/buildbot/test/regressions/test_sourcestamp_revision.py
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,11 @@ | ||
from twisted.trial import unittest | ||
|
||
from buildbot.sourcestamp import SourceStamp | ||
from buildbot.changes.changes import Change | ||
|
||
class TestSourceStampRevision(unittest.TestCase): | ||
def testNoRevision(self): | ||
c = Change(who="catlee", files=["foo"], comments="", branch="b1", revision=None) | ||
ss = SourceStamp(changes=[c]) | ||
|
||
self.assertEquals(ss.revision, None) |