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

lightningnetwork / lnd / 13481548301

23 Feb 2025 09:06AM UTC coverage: 4.031% (-54.8%) from 58.825%
13481548301

Pull #9521

github

web-flow
Merge 1ffbe99fe into 5fe900d18
Pull Request #9521: unit: remove GOACC, use Go 1.20 native coverage functionality

2852 of 70750 relevant lines covered (4.03%)

0.92 hits per line

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

0.0
/sqldb/sqlc/migration.sql.go
1
// Code generated by sqlc. DO NOT EDIT.
2
// versions:
3
//   sqlc v1.25.0
4
// source: migration.sql
5

6
package sqlc
7

8
import (
9
        "context"
10
        "time"
11
)
12

13
const getDatabaseVersion = `-- name: GetDatabaseVersion :one
14
SELECT
15
  version
16
FROM
17
  migration_tracker
18
ORDER BY
19
  version DESC
20
LIMIT 1
21
`
22

23
func (q *Queries) GetDatabaseVersion(ctx context.Context) (int32, error) {
×
24
        row := q.db.QueryRowContext(ctx, getDatabaseVersion)
×
25
        var version int32
×
26
        err := row.Scan(&version)
×
27
        return version, err
×
28
}
×
29

30
const getMigration = `-- name: GetMigration :one
31
SELECT
32
  migration_time
33
FROM
34
  migration_tracker
35
WHERE
36
  version = $1
37
`
38

39
func (q *Queries) GetMigration(ctx context.Context, version int32) (time.Time, error) {
×
40
        row := q.db.QueryRowContext(ctx, getMigration, version)
×
41
        var migration_time time.Time
×
42
        err := row.Scan(&migration_time)
×
43
        return migration_time, err
×
44
}
×
45

46
const setMigration = `-- name: SetMigration :exec
47
INSERT INTO
48
  migration_tracker (version, migration_time) 
49
VALUES ($1, $2)
50
`
51

52
type SetMigrationParams struct {
53
        Version       int32
54
        MigrationTime time.Time
55
}
56

57
func (q *Queries) SetMigration(ctx context.Context, arg SetMigrationParams) error {
×
58
        _, err := q.db.ExecContext(ctx, setMigration, arg.Version, arg.MigrationTime)
×
59
        return err
×
60
}
×
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

© 2025 Coveralls, Inc