mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-07-16 12:08:04 +00:00
fix unit test
This commit is contained in:
+5
-1
@@ -32,5 +32,9 @@ func (s *UtilsSuite) TestDirIsAccessibleNotExist(c *C) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (s *UtilsSuite) TestDirIsAccessibleNotAccessible(c *C) {
|
func (s *UtilsSuite) TestDirIsAccessibleNotAccessible(c *C) {
|
||||||
c.Check(DirIsAccessible(s.tempfile.Name()).Error(), Equals, fmt.Errorf("'%s' is inaccessible, check access rights", s.tempfile.Name()).Error())
|
accessible := DirIsAccessible(s.tempfile.Name())
|
||||||
|
if accessible == nil {
|
||||||
|
c.Fatalf("Test dir should not be accessible: %s", s.tempfile.Name())
|
||||||
|
}
|
||||||
|
c.Check(accessible.Error(), Equals, fmt.Errorf("'%s' is inaccessible, check access rights", s.tempfile.Name()).Error())
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user