You didn't instance the node.
preload gives you a
Resource, in this case it's a
PackedScene resource. You must use
.instance() to create an instance of that scene, and only then you can add it to the tree:
var res = preload("res://test.tscn")
var nodeToLoad = res.instance()
FYI, it says the
p_child parameter is null because the engine fails to cast your resource to a node, because nodes aren't resources.