aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack Palevich <jackpal@google.com>2012-09-28 22:45:39 -0700
committerJack Palevich <jackpal@google.com>2012-09-28 22:45:39 -0700
commit230c04bbb10c73c55d897e744aa265ebd227b3c9 (patch)
tree3e4c1b4d283ca83a6f15d49fd1fc272c692b88b3
parent54d253011a2ec02adc247d6402fce0daaeb27a9f (diff)
downloadAndroidTerm-230c04bbb10c73c55d897e744aa265ebd227b3c9.tar.gz
A test program to help debug issue 149.
-rw-r--r--tests/issue149/colors.go30
1 files changed, 30 insertions, 0 deletions
diff --git a/tests/issue149/colors.go b/tests/issue149/colors.go
new file mode 100644
index 0000000..4f055dc
--- /dev/null
+++ b/tests/issue149/colors.go
@@ -0,0 +1,30 @@
+// Generate a repatable string of characters for fuzz testing.
+
+package main
+
+import (
+ "fmt"
+)
+
+func setFore(c int) {
+ fmt.Printf("\x1b[38;5;%dm", c)
+}
+
+func setBack(c int) {
+ fmt.Printf("\x1b[48;5;%dm", c)
+}
+
+func main() {
+ /*
+ for i := 0; i < 255; i++ {
+ setFore(i)
+ fmt.Printf("Fore Color %d \n", i)
+ }
+ setFore(0)
+ */
+
+ for i := 0; i < 255; i++ {
+ setBack(i)
+ fmt.Printf("Back Color %d \n", i)
+ }
+}