Skip to content
This repository has been archived by the owner on May 12, 2021. It is now read-only.

Commit

Permalink
Merge pull request #528 from teawater/lint
Browse files Browse the repository at this point in the history
Update code to handle lint issues after golangci-lint update to v1.6.0
  • Loading branch information
chavafg authored Apr 9, 2019
2 parents 74639b7 + 01b1cb2 commit 801d792
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 35 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
#

sudo: required
dist: trusty
dist: xenial

os:
- linux
Expand All @@ -15,7 +15,7 @@ language: go
go_import_path: github.com/kata-containers/agent

go:
- "1.10.x"
- "1.11.x"

env:
- target_branch=$TRAVIS_BRANCH
Expand Down
66 changes: 33 additions & 33 deletions grpc_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -869,42 +869,42 @@ func TestPosixRlimitsToRlimits(t *testing.T) {
assert := assert.New(t)

expectedRlimits := []configs.Rlimit{
{unix.RLIMIT_CPU, 100, 120},
{unix.RLIMIT_FSIZE, 100, 120},
{unix.RLIMIT_DATA, 100, 120},
{unix.RLIMIT_STACK, 100, 120},
{unix.RLIMIT_CORE, 100, 120},
{unix.RLIMIT_RSS, 100, 120},
{unix.RLIMIT_NPROC, 100, 120},
{unix.RLIMIT_NOFILE, 100, 120},
{unix.RLIMIT_MEMLOCK, 100, 120},
{unix.RLIMIT_AS, 100, 120},
{unix.RLIMIT_LOCKS, 100, 120},
{unix.RLIMIT_SIGPENDING, 100, 120},
{unix.RLIMIT_MSGQUEUE, 100, 120},
{unix.RLIMIT_NICE, 100, 120},
{unix.RLIMIT_RTPRIO, 100, 120},
{unix.RLIMIT_RTTIME, 100, 120},
{Type: unix.RLIMIT_CPU, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_FSIZE, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_DATA, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_STACK, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_CORE, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_RSS, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_NPROC, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_NOFILE, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_MEMLOCK, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_AS, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_LOCKS, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_SIGPENDING, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_MSGQUEUE, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_NICE, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_RTPRIO, Hard: 100, Soft: 120},
{Type: unix.RLIMIT_RTTIME, Hard: 100, Soft: 120},
}

posixRlimits := []specs.POSIXRlimit{
{"RLIMIT_CPU", 100, 120},
{"RLIMIT_FSIZE", 100, 120},
{"RLIMIT_DATA", 100, 120},
{"RLIMIT_STACK", 100, 120},
{"RLIMIT_CORE", 100, 120},
{"RLIMIT_RSS", 100, 120},
{"RLIMIT_NPROC", 100, 120},
{"RLIMIT_NOFILE", 100, 120},
{"RLIMIT_MEMLOCK", 100, 120},
{"RLIMIT_AS", 100, 120},
{"RLIMIT_LOCKS", 100, 120},
{"RLIMIT_SIGPENDING", 100, 120},
{"RLIMIT_MSGQUEUE", 100, 120},
{"RLIMIT_NICE", 100, 120},
{"RLIMIT_RTPRIO", 100, 120},
{"RLIMIT_RTTIME", 100, 120},
{"RLIMIT_UNSUPPORTED", 0, 0},
{Type: "RLIMIT_CPU", Hard: 100, Soft: 120},
{Type: "RLIMIT_FSIZE", Hard: 100, Soft: 120},
{Type: "RLIMIT_DATA", Hard: 100, Soft: 120},
{Type: "RLIMIT_STACK", Hard: 100, Soft: 120},
{Type: "RLIMIT_CORE", Hard: 100, Soft: 120},
{Type: "RLIMIT_RSS", Hard: 100, Soft: 120},
{Type: "RLIMIT_NPROC", Hard: 100, Soft: 120},
{Type: "RLIMIT_NOFILE", Hard: 100, Soft: 120},
{Type: "RLIMIT_MEMLOCK", Hard: 100, Soft: 120},
{Type: "RLIMIT_AS", Hard: 100, Soft: 120},
{Type: "RLIMIT_LOCKS", Hard: 100, Soft: 120},
{Type: "RLIMIT_SIGPENDING", Hard: 100, Soft: 120},
{Type: "RLIMIT_MSGQUEUE", Hard: 100, Soft: 120},
{Type: "RLIMIT_NICE", Hard: 100, Soft: 120},
{Type: "RLIMIT_RTPRIO", Hard: 100, Soft: 120},
{Type: "RLIMIT_RTTIME", Hard: 100, Soft: 120},
{Type: "RLIMIT_UNSUPPORTED", Hard: 0, Soft: 0},
}

rlimits := posixRlimitsToRlimits(posixRlimits)
Expand Down

0 comments on commit 801d792

Please sign in to comment.