Skip to content

Commit

Permalink
review: split test files
Browse files Browse the repository at this point in the history
  • Loading branch information
ldez committed Nov 16, 2024
1 parent 4d7f702 commit 28187fd
Show file tree
Hide file tree
Showing 14 changed files with 140 additions and 112 deletions.
11 changes: 11 additions & 0 deletions testdata/src/disablebuiltin/binary.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package disablebuiltin

type Binary struct{} // want `the methods of "Binary" use pointer receiver and non-pointer receiver.`

func (b Binary) MarshalBinary() ([]byte, error) {
panic("not implemented")
}

func (b *Binary) UnmarshalBinary(data []byte) error {
panic("not implemented")
}
57 changes: 0 additions & 57 deletions testdata/src/disablebuiltin/disablebuiltin.go

This file was deleted.

11 changes: 11 additions & 0 deletions testdata/src/disablebuiltin/gob.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package disablebuiltin

type Gob struct{} // want `the methods of "Gob" use pointer receiver and non-pointer receiver.`

func (g Gob) GobEncode() ([]byte, error) {
panic("not implemented")
}

func (g *Gob) GobDecode(data []byte) error {
panic("not implemented")
}
11 changes: 11 additions & 0 deletions testdata/src/disablebuiltin/json.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package disablebuiltin

type JSON struct{} // want `the methods of "JSON" use pointer receiver and non-pointer receiver.`

func (j JSON) MarshalJSON() ([]byte, error) {
panic("not implemented")
}

func (j *JSON) UnmarshalJSON(b []byte) error {
panic("not implemented")
}
11 changes: 11 additions & 0 deletions testdata/src/disablebuiltin/text.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package disablebuiltin

type Text struct{} // want `the methods of "Text" use pointer receiver and non-pointer receiver.`

func (t Text) MarshalText() ([]byte, error) {
panic("not implemented")
}

func (t *Text) UnmarshalText(b []byte) error {
panic("not implemented")
}
13 changes: 13 additions & 0 deletions testdata/src/disablebuiltin/xml.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package disablebuiltin

import "encoding/xml"

type XML struct{} // want `the methods of "XML" use pointer receiver and non-pointer receiver.`

func (x XML) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
panic("not implemented")
}

func (x *XML) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
panic("not implemented")
}
13 changes: 13 additions & 0 deletions testdata/src/disablebuiltin/yaml.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package disablebuiltin

type Node struct{}

type YAML struct{} // want `the methods of "YAML" use pointer receiver and non-pointer receiver.`

func (j YAML) MarshalYAML() (any, error) {
panic("not implemented")
}

func (j *YAML) UnmarshalYAML(value *Node) error {
panic("not implemented")
}
11 changes: 11 additions & 0 deletions testdata/src/excluded/binary.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package excluded

type Binary struct{}

func (b Binary) MarshalBinary() ([]byte, error) {
panic("not implemented")
}

func (b *Binary) UnmarshalBinary(data []byte) error {
panic("not implemented")
}
55 changes: 0 additions & 55 deletions testdata/src/excluded/excluded.go

This file was deleted.

11 changes: 11 additions & 0 deletions testdata/src/excluded/gob.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package excluded

type Gob struct{}

func (g Gob) GobEncode() ([]byte, error) {
panic("not implemented")
}

func (g *Gob) GobDecode(data []byte) error {
panic("not implemented")
}
11 changes: 11 additions & 0 deletions testdata/src/excluded/json.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package excluded

type JSON struct{}

func (j JSON) MarshalJSON() ([]byte, error) {
panic("not implemented")
}

func (j *JSON) UnmarshalJSON(b []byte) error {
panic("not implemented")
}
11 changes: 11 additions & 0 deletions testdata/src/excluded/text.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
package excluded

type Text struct{}

func (t Text) MarshalText() ([]byte, error) {
panic("not implemented")
}

func (t *Text) UnmarshalText(b []byte) error {
panic("not implemented")
}
13 changes: 13 additions & 0 deletions testdata/src/excluded/xml.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package excluded

import "encoding/xml"

type XML struct{}

func (x XML) MarshalXML(e *xml.Encoder, start xml.StartElement) error {
panic("not implemented")
}

func (x *XML) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error {
panic("not implemented")
}
13 changes: 13 additions & 0 deletions testdata/src/excluded/yaml.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package excluded

type Node struct{}

type YAML struct{}

func (j YAML) MarshalYAML() (any, error) {
panic("not implemented")
}

func (j *YAML) UnmarshalYAML(value *Node) error {
panic("not implemented")
}

0 comments on commit 28187fd

Please sign in to comment.