def METHOD_NAME(self, mock):
    mock.atomcoords = np.array([[
        [-1, 0, 0],
        [0, 0, 0],
        [1, 0, 0]]])
    # The periods are for Python2.
    mock.atomcharges = {'mulliken': [1/2., -1., 1/2.]}
    mock.atomnos = np.ones(mock.atomcoords.shape[1])
    x = Moments(mock).calculate()
    assert np.count_nonzero(x[1]) == 0
    assert_almost_equal(x[2] / 4.80320423, [1, 0, 0, -0.5, 0, -0.5])