This is sufficient, since LaTeX defines commands \<env> and \end<env> when you execute \newenvironment{<env>}. However, just to be on the safe side, you may want to remove any previous definitions of \end<env> that may have been defined using \def\end<env>{...} for whatever reason:
\ifcsmacro{myenvironment}{}{
\let\endmyenvironment\undefined%
\newenvironment{myenvironment}{Not seen so far.}{End.}
}
Here, \undefined is an undefined macro. It may just as well have been anything that is undefined, like \thismacrodoesnotexist. Of course, if there is concern that \end<env> might be important, then you should test for that as well before defining <env>, possibly by nesting it within the <false> condition of \ifcsmacro.
\provideenvironment, which apparently does not exist. However, http://tex.stackexchange.com/a/20691/3751 presents a pure-Latex implementation of it. – Daniel Jan 18 '12 at 15:52\endmyenvironmentas\end{myenv}does\endmyenv(after some sanity testing) – kahen Jan 18 '12 at 16:54\provideenvironment. I think that could be ok, but I was looking for a simple high level test usingetoolbox, since I have that package already loaded. If\provideenvironmentexisted in plain LaTeX, I surely would use it. – ASdeL Jan 18 '12 at 19:54