<- Back to shtanton's homepage
aboutsummaryrefslogtreecommitdiff
path: root/walk/walk_test.go
diff options
context:
space:
mode:
authorCharlie Stanton <charlie@shtanton.xyz>2024-03-30 20:53:09 +0000
committerCharlie Stanton <charlie@shtanton.xyz>2024-03-30 20:53:09 +0000
commit976d96af62945178f3a3ab572620026df75003cf (patch)
treecdd381b235b423522baa08a36cc0a24e7d76de4a /walk/walk_test.go
parent7a9f00b9bd39173494ea734b899a9f099dafb306 (diff)
downloadstred-go-976d96af62945178f3a3ab572620026df75003cf.tar
Remove obsolete walk package tests
Diffstat (limited to 'walk/walk_test.go')
-rw-r--r--walk/walk_test.go45
1 files changed, 0 insertions, 45 deletions
diff --git a/walk/walk_test.go b/walk/walk_test.go
deleted file mode 100644
index 759c501..0000000
--- a/walk/walk_test.go
+++ /dev/null
@@ -1,45 +0,0 @@
-package walk
-
-import (
- "testing"
- "log"
-)
-
-func TestValueIter(t *testing.T) {
- values := ValueList{
- NumberValue(1),
- NumberValue(2),
- NumberValue(3),
- }
-
- valuesCopy := ValueList{}
-
- iter := NewValueIter(values)
-
- for {
- edible := iter.Next()
- if edible == nil {
- break
- }
-
- log.Println(edible)
-
- value, isValue := edible.(Value)
-
- if !isValue {
- t.Fatalf("Iterator produced a non-value")
- }
-
- valuesCopy = append(valuesCopy, value)
- }
-
- if len(values) != len(valuesCopy) {
- t.Fatalf("iter gave the wrong number of values")
- }
-
- for i, value := range values {
- if value != valuesCopy[i] {
- t.Fatalf("iter produced an incorrect value")
- }
- }
-}