github.com/whtcorpsinc/MilevaDB-Prod@v0.0.0-20211104133533-f57f4be3b597/interlock/aggfuncs/func_stddevsamp_test.go (about)

     1  package aggfuncs_test
     2  
     3  import (
     4  	. "github.com/whtcorpsinc/check"
     5  	"github.com/whtcorpsinc/BerolinaSQL/ast"
     6  	"github.com/whtcorpsinc/BerolinaSQL/allegrosql"
     7  )
     8  
     9  func (s *testSuite) TestMergePartialResult4Stddevsamp(c *C) {
    10  	tests := []aggTest{
    11  		builPosetDaggTester(ast.AggFuncStddevSamp, allegrosql.TypeDouble, 5, 1.5811388300841898, 1, 1.407885953173359),
    12  	}
    13  	for _, test := range tests {
    14  		s.testMergePartialResult(c, test)
    15  	}
    16  }
    17  
    18  func (s *testSuite) TestStddevsamp(c *C) {
    19  	tests := []aggTest{
    20  		builPosetDaggTester(ast.AggFuncStddevSamp, allegrosql.TypeDouble, 5, nil, 1.5811388300841898),
    21  	}
    22  	for _, test := range tests {
    23  		s.testAggFunc(c, test)
    24  	}
    25  }