mirror of https://github.com/gogits/gogs.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.0 KiB
39 lines
1.0 KiB
12 years ago
|
// Copyright (c) 2013 GPMGo Members. All rights reserved.
|
||
|
// Use of this source code is governed by a MIT-style
|
||
|
// license that can be found in the LICENSE file.
|
||
|
|
||
|
package main
|
||
|
|
||
|
import (
|
||
|
"fmt"
|
||
12 years ago
|
"testing"
|
||
12 years ago
|
"time"
|
||
12 years ago
|
)
|
||
|
|
||
12 years ago
|
func TestGPM(t *testing.T) {
|
||
12 years ago
|
fmt.Println("gopm v0.2.2 Build 0524")
|
||
12 years ago
|
|
||
12 years ago
|
fmt.Println("\nBuilding gopm application...")
|
||
12 years ago
|
// Build application.
|
||
|
var args []string
|
||
|
args = append(args, "build")
|
||
|
executeCommand("go", args)
|
||
|
|
||
12 years ago
|
fmt.Println("\nStart testing command Install...")
|
||
|
fmt.Println("This package depends on `install_test2`.")
|
||
|
time.Sleep(2 * time.Second)
|
||
12 years ago
|
args = make([]string, 0)
|
||
|
args = append(args, "install")
|
||
12 years ago
|
args = append(args, "github.com/GPMGoTest/install_test")
|
||
12 years ago
|
executeCommand("gopm", args)
|
||
12 years ago
|
|
||
12 years ago
|
fmt.Println("\nStart testing command Remove...")
|
||
|
fmt.Println("Let's remove `install_test` and `install_test2`.")
|
||
|
time.Sleep(2 * time.Second)
|
||
12 years ago
|
args = make([]string, 0)
|
||
|
args = append(args, "remove")
|
||
12 years ago
|
args = append(args, "github.com/GPMGoTest/install_test")
|
||
|
args = append(args, "github.com/GPMGoTest/install_test2")
|
||
12 years ago
|
executeCommand("gopm", args)
|
||
12 years ago
|
}
|