[Groonga-commit] groonga/grnxx at 8a4246b [master] Gnx: add comments.

Back to archive index

susumu.yata null+****@clear*****
Thu May 7 12:25:07 JST 2015


susumu.yata	2015-05-07 12:25:07 +0900 (Thu, 07 May 2015)

  New Revision: 8a4246b694c33bad924cc29d65cc84e5ae77195d
  https://github.com/groonga/grnxx/commit/8a4246b694c33bad924cc29d65cc84e5ae77195d

  Message:
    Gnx: add comments.

  Modified files:
    go3/gnx/grn_test.go

  Modified: go3/gnx/grn_test.go (+9 -0)
===================================================================
--- go3/gnx/grn_test.go    2015-05-07 12:14:25 +0900 (29fb19f)
+++ go3/gnx/grn_test.go    2015-05-07 12:25:07 +0900 (cc610b1)
@@ -9,6 +9,8 @@ import (
 	"testing"
 )
 
+// createTempGrnDB() creates a database for tests.
+// The database must be removed with removeTempGrnDB().
 func createTempGrnDB(tb testing.TB) (string, string, *GrnDB) {
 	dirPath, err := ioutil.TempDir("", "grn_test")
 	if err != nil {
@@ -23,6 +25,7 @@ func createTempGrnDB(tb testing.TB) (string, string, *GrnDB) {
 	return dirPath, dbPath, db
 }
 
+// removeTempGrnDB() removes a database created with createTempGrnDB().
 func removeTempGrnDB(tb testing.TB, dirPath string, db *GrnDB) {
 	if err := db.Close(); err != nil {
 		os.RemoveAll(dirPath)
@@ -33,6 +36,9 @@ func removeTempGrnDB(tb testing.TB, dirPath string, db *GrnDB) {
 	}
 }
 
+// createTempGrnTable() creates a database and a table for tests.
+// createTempGrnTable() uses createTempGrnDB() to create a database, so the
+// database must be removed with removeTempGrnDB().
 func createTempGrnTable(tb testing.TB, name string, options *TableOptions) (
 	string, string, *GrnDB, *GrnTable) {
 	dirPath, dbPath, db := createTempGrnDB(tb)
@@ -44,6 +50,9 @@ func createTempGrnTable(tb testing.TB, name string, options *TableOptions) (
 	return dirPath, dbPath, db, table
 }
 
+// createTempGrnColumn() creates a database, a table, and a column for tests.
+// createTempGrnColumn() uses createTempGrnDB() to create a database, so the
+// database must be removed with removeTempGrnDB().
 func createTempGrnColumn(tb testing.TB, tableName string,
 	tableOptions *TableOptions, columnName string, valueType string,
 	columnOptions *ColumnOptions) (
-------------- next part --------------
HTML����������������������������...
다운로드 



More information about the Groonga-commit mailing list
Back to archive index