Skip to content
This repository has been archived by the owner on Feb 26, 2023. It is now read-only.

Commit

Permalink
Add pap field
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyaglow committed Nov 29, 2018
1 parent bffd341 commit fe0bb5f
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions process_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@ import (
func TestObservableConstructor(t *testing.T) {
var cases = []struct {
data string
tlp int
tlp, pap int
dataType string
}{
{"1.1.1.1", 0, "ip"},
{"https://subdomain.domain.com/route/query?param=val", 1, "url"},
{"subdomain.domain.com", 2, "domain"},
{"email.address@domain.com", 3, "mail"},
{"email+address@domain.com", 3, "mail"},
{"a94a8fe5ccb19ba61c4c0873d391e987982fbbd3", 0, "hash"},
{"randomdata", 1, "other"},
{"1.1.1.1", 0, 0, "ip"},
{"https://subdomain.domain.com/route/query?param=val", 1, 1, "url"},
{"subdomain.domain.com", 2, 2, "domain"},
{"email.address@domain.com", 3, 3, "mail"},
{"email+address@domain.com", 3, 3, "mail"},
{"a94a8fe5ccb19ba61c4c0873d391e987982fbbd3", 0, 0, "hash"},
{"randomdata", 1, 1, "other"},
}

for _, c := range cases {
a := newArtifact(c.data, c.tlp)
a := newArtifact(c.data, c.tlp, c.pap)
if a.Description() != c.data {
t.Errorf("need %s, got %s", c.data, a.Description())
}
Expand Down

0 comments on commit fe0bb5f

Please sign in to comment.