package ssha_test

import (
	"testing"

	"github.com/jsimonetti/pwscheme/ssha"
)

func TestValidate(t *testing.T) {
	pass := "test123"
	hash := "{SSHA}lJj507aRaXGguk1uTQoKmKQRV/7N1oB7pmhWdw=="

	if res, err := ssha.Validate(pass, hash); res != true {
		t.Error("Validate password fails", err)
	}
}

func TestGenerate(t *testing.T) {
	pass := "test123"
	hash := ssha.Generate(pass)

	if res, err := ssha.Validate(pass, hash); res != true {
		t.Error("Generate of password fails", err)
	}
}

package ssha_test

import (
	"testing"

	"github.com/jsimonetti/pwscheme/ssha"
)

func TestValidate(t *testing.T) {
	pass := "test123"
	hash := "{SSHA}JFZFs0oHzxbMwkSJmYVeI8MnTDy/276a"

	if res, err := ssha.Validate(pass, hash); res != true {
		t.Error("Validate password fails", err)
	}
}

func TestGenerate(t *testing.T) {
	pass := "test123"
	hash := ssha.Generate(pass)

	if res, err := ssha.Validate(pass, hash); res != true {
		t.Error("Generate of password fails", err)
	}
}

Add an actually working hash
Add an actually working hash

Signed-off-by: Jeroen Simonetti <fd3fb11d20dd2b55b441515e5cc120796bf92f11@simonetti.nl>
