• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

fogfish / swarm / 11113666559

30 Sep 2024 08:30PM UTC coverage: 59.94% (-0.5%) from 60.391%
11113666559

push

github

web-flow
kernel v0.20.1 with minor improvements (#94)

18 of 53 new or added lines in 8 files covered. (33.96%)

3 existing lines in 3 files now uncovered.

998 of 1665 relevant lines covered (59.94%)

0.66 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

75.0
/errors.go
1
//
2
// Copyright (C) 2021 - 2022 Dmitry Kolesnikov
3
//
4
// This file may be modified and distributed under the terms
5
// of the Apache License Version 2.0. See the LICENSE file for details.
6
// https://github.com/fogfish/swarm
7
//
8

9
package swarm
10

11
import (
12
        "fmt"
13
        "time"
14

15
        "github.com/fogfish/faults"
16
)
17

18
const (
19
        ErrServiceIO = faults.Type("service i/o failed")
20
        ErrEnqueue   = faults.Type("enqueue is failed")
21
        ErrDequeue   = faults.Type("dequeue is failed")
22
)
23

24
type errTimeout struct {
25
        op    string
26
        timer time.Duration
27
}
28

29
func ErrTimeout(op string, timer time.Duration) error {
1✔
30
        return errTimeout{
1✔
31
                op:    op,
1✔
32
                timer: timer,
1✔
33
        }
1✔
34
}
1✔
35

36
func (err errTimeout) Error() string {
1✔
37
        return fmt.Sprintf("timeout %s after %s", err.op, err.timer)
1✔
38
}
1✔
39

NEW
40
func (err errTimeout) Timeout() time.Duration {
×
NEW
41
        return err.timer
×
NEW
42
}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc