1
0
mirror of https://github.com/minio/mc.git synced 2025-11-12 01:02:26 +03:00

separate mutex for internal and external locking

This commit is contained in:
Anand Babu (AB) Periasamy
2015-09-09 17:36:33 -07:00
committed by Harshavardhana
parent 942a633c67
commit 3a9b2064f6
2 changed files with 155 additions and 139 deletions

View File

@@ -35,3 +35,18 @@ func (s *MySuite) TestSetTheme(c *C) {
_, ok := Theme["unknown"]
c.Assert(ok, Equals, true)
}
func (s *MySuite) TestLock(c *C) {
Lock()
Print("") // Test for deadlocks.
Unlock()
}
func (s *MySuite) TestTesting(c *C) {
// Enable testing
IsTesting = true
Fatalln("THIS IS A TEST MESSAGE. PLEASE INGORE.")
c.Assert(IsExited, Equals, true)
// reset back
IsExited = false
}