Rename ConnectToWifiNetwork() to JoinWifiNetwork() for brevety and clarity
This commit is contained in:
parent
13267b2d5a
commit
5f6dcd2253
|
@ -101,7 +101,7 @@ func configureWifi() {
|
|||
}
|
||||
|
||||
log.Println("connecting module to wifi network")
|
||||
if err := updater.ConnectToWifiNetwork(ssid, true); err != nil {
|
||||
if err := updater.JoinWifiNetwork(ssid, true); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
log.Printf("you can now switch to the wifi network and start phase '%s'", phaseUpdateThenReboot)
|
||||
|
|
|
@ -136,8 +136,8 @@ func (u *Updater) RemoveWifiNetwork(ssid string) (bool, error) {
|
|||
|
||||
}
|
||||
|
||||
// ConnectToWifiNetwork asks the ReachRS module to connect to the given WiFi network
|
||||
func (u *Updater) ConnectToWifiNetwork(ssid string, waitDisconnect bool) error {
|
||||
// JoinWifiNetwork asks the ReachRS module to join the given WiFi network
|
||||
func (u *Updater) JoinWifiNetwork(ssid string, waitDisconnect bool) error {
|
||||
|
||||
var err error
|
||||
var wg sync.WaitGroup
|
||||
|
|
|
@ -85,7 +85,7 @@ func TestClientCRUDWiFiNetwork(t *testing.T) {
|
|||
|
||||
}
|
||||
|
||||
func TestClientWifiNetworkConnect(t *testing.T) {
|
||||
func TestClientWifiNetworkJoin(t *testing.T) {
|
||||
|
||||
if !*runUpdaterIntegrationTests {
|
||||
t.Skip("To run this test, use: go test -updater-integration")
|
||||
|
@ -110,7 +110,7 @@ func TestClientWifiNetworkConnect(t *testing.T) {
|
|||
t.Errorf("AddWifiNetwork() -> done: got '%v', expected '%v'", g, e)
|
||||
}
|
||||
|
||||
if err := client.ConnectToWifiNetwork(ssid, true); err != nil {
|
||||
if err := client.JoinWifiNetwork(ssid, true); err != nil {
|
||||
t.Error(err)
|
||||
}
|
||||
|
||||
|
|
Reference in New Issue