| 320 | } |
| 321 | |
| 322 | func (s *PackagePoolSuite) TestStat(c *C) { |
| 323 | path, err := s.pool.Import(s.debFile, filepath.Base(s.debFile), &s.checksum, false, s.cs) |
| 324 | c.Check(err, IsNil) |
| 325 | |
| 326 | info, err := s.pool.Stat(path) |
| 327 | c.Assert(err, IsNil) |
| 328 | c.Check(info.Size(), Equals, int64(2738)) |
| 329 | |
| 330 | _, err = s.pool.Stat("do/es/ntexist") |
| 331 | c.Assert(os.IsNotExist(err), Equals, true) |
| 332 | } |
| 333 | |
| 334 | func (s *PackagePoolSuite) TestOpen(c *C) { |
| 335 | path, err := s.pool.Import(s.debFile, filepath.Base(s.debFile), &s.checksum, false, s.cs) |