blob: 67c30cc83c0430baa6df7e86e8ca35c676631e8e [file] [log] [blame]
package main
import (
"testing"
"go.fuchsia.dev/fuchsia/tools/bootserver_old/tests"
)
func TestWriteFirmwareWithType(t *testing.T) {
instance, cleanup := bootserver.StartQemu(t, "netsvc.all-features=true, netsvc.netboot=true", "full")
defer cleanup()
logPattern := []bootserver.LogMatch{
{"Received request from ", true},
{"Proceeding with nodename ", true},
{"Transfer starts", true},
{"Transfer ends successfully", true},
{"Issued reboot command to", true},
}
bootserver.CmdSearchLog(
t, logPattern,
bootserver.ToolPath(t, "bootserver"), "-n", bootserver.DefaultNodename,
"--firmware-foo", bootserver.FirmwarePath(t), "-1", "--fail-fast")
instance.WaitForLogMessage("netsvc: Running FIRMWARE Paver (firmware type 'foo')")
}