mirror of
https://github.com/go-sylixos/elvish.git
synced 2024-12-05 03:17:50 +08:00
71cd3835bc
Qualified imports of pkg/tt outnumber unqualified (27 to 24). Improve consistency, and clarity, by changing the dot (unqualified) imports of that package symbols to qualified.
20 lines
373 B
Go
20 lines
373 B
Go
package vals
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"src.elv.sh/pkg/tt"
|
|
)
|
|
|
|
type dissocer struct{}
|
|
|
|
func (dissocer) Dissoc(any) any { return "custom ret" }
|
|
|
|
func TestDissoc(t *testing.T) {
|
|
tt.Test(t, tt.Fn("Dissoc", Dissoc), tt.Table{
|
|
Args(MakeMap("k1", "v1", "k2", "v2"), "k1").Rets(eq(MakeMap("k2", "v2"))),
|
|
Args(dissocer{}, "x").Rets("custom ret"),
|
|
Args("", "x").Rets(nil),
|
|
})
|
|
}
|