private static Tensor assertTensorField(Tensor expectedTensor, DocumentPut put, String tensorFieldName) {
        Document doc = put.getDocument();
        assertEquals("testtensor", doc.getId().getDocType());
        assertEquals(TENSOR_DOC_ID, doc.getId().toString());
        TensorFieldValue fieldValue = (TensorFieldValue)doc.getFieldValue(doc.getField(tensorFieldName));
        assertEquals(expectedTensor, fieldValue.getTensor().get());
        return fieldValue.getTensor().get();
    }
Tests parsing of various tensor values set at the root, i.e. no 'cells', 'blocks' or 'values'
document/src/test/java/com/yahoo/document/json/JsonReaderTestCase.java