about summary refs log tree commit diff stats
path: root/el/simple_test.go
diff options
context:
space:
mode:
authorMarkus Wüstenberg2020-12-10 13:00:23 +0100
committerGitHub2020-12-10 13:00:23 +0100
commita76262652b227c95ce140f3698c46f59b79354ac (patch)
tree15987ad4a4a4f830f0df9fc110faf667fe83514a /el/simple_test.go
parenta7e24c6cddaafb98091c3989c9da7779eeba30b5 (diff)
downloadgomponents-a76262652b227c95ce140f3698c46f59b79354ac.tar.lz
gomponents-a76262652b227c95ce140f3698c46f59b79354ac.tar.zst
gomponents-a76262652b227c95ce140f3698c46f59b79354ac.zip
Move elements and attributes into html package (#52)
This makes it easier to use dot-imports.

Also updated the readme and examples with new usage, and move the `Classes` helper into the `components` package.
Diffstat (limited to 'el/simple_test.go')
-rw-r--r--el/simple_test.go97
1 files changed, 0 insertions, 97 deletions
diff --git a/el/simple_test.go b/el/simple_test.go
deleted file mode 100644
index 2621982..0000000
--- a/el/simple_test.go
+++ /dev/null
@@ -1,97 +0,0 @@
-package el_test
-
-import (
-	"fmt"
-	"testing"
-
-	g "github.com/maragudk/gomponents"
-	"github.com/maragudk/gomponents/assert"
-	"github.com/maragudk/gomponents/el"
-)
-
-func TestSimpleElements(t *testing.T) {
-	cases := map[string]func(...g.Node) g.NodeFunc{
-		"address":    el.Address,
-		"article":    el.Article,
-		"aside":      el.Aside,
-		"audio":      el.Audio,
-		"blockquote": el.BlockQuote,
-		"body":       el.Body,
-		"button":     el.Button,
-		"canvas":     el.Canvas,
-		"cite":       el.Cite,
-		"code":       el.Code,
-		"colgroup":   el.ColGroup,
-		"data":       el.Data,
-		"datalist":   el.DataList,
-		"details":    el.Details,
-		"dialog":     el.Dialog,
-		"div":        el.Div,
-		"dl":         el.Dl,
-		"fieldset":   el.FieldSet,
-		"figure":     el.Figure,
-		"footer":     el.Footer,
-		"head":       el.Head,
-		"header":     el.Header,
-		"hgroup":     el.HGroup,
-		"html":       el.HTML,
-		"iframe":     el.IFrame,
-		"legend":     el.Legend,
-		"li":         el.Li,
-		"main":       el.Main,
-		"menu":       el.Menu,
-		"meter":      el.Meter,
-		"nav":        el.Nav,
-		"noscript":   el.NoScript,
-		"object":     el.Object,
-		"ol":         el.Ol,
-		"optgroup":   el.OptGroup,
-		"p":          el.P,
-		"picture":    el.Picture,
-		"pre":        el.Pre,
-		"script":     el.Script,
-		"section":    el.Section,
-		"span":       el.Span,
-		"style":      el.Style,
-		"summary":    el.Summary,
-		"svg":        el.SVG,
-		"table":      el.Table,
-		"tbody":      el.TBody,
-		"td":         el.Td,
-		"tfoot":      el.TFoot,
-		"th":         el.Th,
-		"thead":      el.THead,
-		"tr":         el.Tr,
-		"ul":         el.Ul,
-	}
-
-	for name, fn := range cases {
-		t.Run(fmt.Sprintf("should output %v", name), func(t *testing.T) {
-			n := fn(g.Attr("id", "hat"))
-			assert.Equal(t, fmt.Sprintf(`<%v id="hat"></%v>`, name, name), n)
-		})
-	}
-}
-
-func TestSimpleVoidKindElements(t *testing.T) {
-	cases := map[string]func(...g.Node) g.NodeFunc{
-		"area":   el.Area,
-		"base":   el.Base,
-		"br":     el.Br,
-		"col":    el.Col,
-		"embed":  el.Embed,
-		"hr":     el.Hr,
-		"link":   el.Link,
-		"meta":   el.Meta,
-		"param":  el.Param,
-		"source": el.Source,
-		"wbr":    el.Wbr,
-	}
-
-	for name, fn := range cases {
-		t.Run(fmt.Sprintf("should output %v", name), func(t *testing.T) {
-			n := fn(g.Attr("id", "hat"))
-			assert.Equal(t, fmt.Sprintf(`<%v id="hat">`, name), n)
-		})
-	}
-}