mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Fix TPExporter not properly closing the zipWriter
This commit is contained in:
@@ -105,10 +105,10 @@ func (self *TPExporter) Run() error {
|
||||
self.removeFiles()
|
||||
return err
|
||||
}
|
||||
if self.compress {
|
||||
if err := self.zipWritter.Close(); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
if self.compress {
|
||||
if err := self.zipWritter.Close(); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
|
||||
@@ -124,4 +124,13 @@ func TestTutLclLoadTariffPlanFromFolder(t *testing.T) {
|
||||
t.Error(reply)
|
||||
}
|
||||
time.Sleep(time.Duration(*waitRater) * time.Millisecond) // Give time for scheduler to execute topups
|
||||
|
||||
}
|
||||
|
||||
func TestShutdown (t *testing.T) {
|
||||
if !*testLocal {
|
||||
return
|
||||
}
|
||||
exec.Command("pkill", "cgr-engine").Run() // Just to make sure another one is not running, bit brutal maybe we can fine tune it
|
||||
time.Sleep(time.Duration(*waitRater) * time.Millisecond)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user