I've read in many places that a tree is a special case of a directed acyclic graph where each vertex has only one predecessor. This implies a tree must be directed. But then there are other definitions that say: "A tree is a type of connected graph. An directed graph is a tree if it is connected, has no cycles and all vertices have at most one parent. An undirected graph is considered a tree if it is connected, has $|V|-1$ edges and is acyclic (a graph that satisfies any two of these properties satisfies all three)." (from here: https://en.wikibooks.org/wiki/Graph_Theory/Trees).
This seems to suggest a tree can be undirected as well. I thought the catch was that a graph that is acyclic has to be directed. Otherwise, a single edge of an undirected graph becomes a cycle since you can traverse that edge and back, ending up at the same vertex.
But then, I came across problem 22.4-3 that says "Give an algorithm that determines weather or not an undirected graph G contains a cycle".
Now I'm confused. If a tree is a special case of a DAG, it must be directed. But other definitions suggest there can be undirected trees as well. And why doesn't a single edge of an undirected graph make it cyclic?