Skip to content

Commit

Permalink
cleanup tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jcp19 committed Jan 29, 2025
1 parent e92f444 commit eddaf6a
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 125 deletions.
24 changes: 0 additions & 24 deletions src/test/resources/regressions/features/globals/scion-like01.go

This file was deleted.

24 changes: 0 additions & 24 deletions src/test/resources/regressions/features/globals/scion-like02.go

This file was deleted.

28 changes: 0 additions & 28 deletions src/test/resources/regressions/features/globals/scion-like03.go

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

package onehop

// ##(-I ../../..)
// ##(-I ../../)

import "scion/path"
import "path"

const PathType path.Type = 2

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

package path

// ##(-I ../../)
// ##(-I ../)

// This approach is sound, assuming that the paths below are unique per a package.
// This assumption is not problematic, and is similar to the assumption we make for
Expand All @@ -14,6 +14,23 @@ package path

// @ import "monotonicset"

/*@
pred PkgInv() {
acc(&registeredPaths) &&
registeredKeys.Inv() &&
(forall i uint16 :: 0 <= i && i < maxPathType ==>
registeredPaths[i].inUse == registeredKeys.FContains(i))
}
ghost
decreases
pure func RegisteredTypes() monotonicset.BoundedMonotonicSet {
return registeredKeys
}
@*/

const maxPathType = 256

var registeredPaths /*@@@*/ [maxPathType]metadata
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@

package scion

// ##(-I ../../..)
// ##(-I ../../)

import "scion/path"
import "path"

const PathType path.Type = 1

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

package scion

// ##(-I ..)
// ##(-I .)

// Example inspired by how PathTypes are registered in the SCION border router.
// Based on https://github.com/viperproject/VerifiedSCION/tree/master/pkg/slayers/scion.go
Expand All @@ -19,9 +19,9 @@ import (
// @ importRequires path.PkgInv()
// @ importRequires path.RegisteredTypes().DoesNotContain(1) &&
// @ path.RegisteredTypes().DoesNotContain(2)
// @ "scion/path"
"scion/path/onehop"
"scion/path/scion"
// @ "path"
"path/onehop"
"path/scion"
)

// We should introduce preconditions and postconditions to this function to guarantee that
Expand Down

This file was deleted.

19 changes: 0 additions & 19 deletions src/test/resources/same_package/pkg_init/scion/scion_spec.gobra

This file was deleted.

0 comments on commit eddaf6a

Please sign in to comment.