Depth test not working

I am using OpenGL ES 2.0 on iOS. I enabled DEPTH_TEST, but still object that should be hidden are rendered.
See screenshots:

http://postimg.org/image/9kp5ltcx7/50d44327/
http://postimg.org/image/t70ga5kw7/

In the seconds image, the green rectangle should be hidden by the red rectangle.
I use the following code in my rendering:

glClearColor(bgColor.r, bgColor.g, bgColor.b, bgColor.a);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);

glEnable(GL_DEPTH_TEST | GL_CULL_FACE);

What i could miss?

This is garbage. The constants GL_DEPTH_TEST (0x0B71) and GL_CULL_FACE (0x0B44) are not flags (GL_COLOR_BUFFER_BIT and GL_DEPTH_BUFFER_BIT are, hence the _BIT).
You have to call glEnable(GL_DEPTH_TEST) and glEnable(GL_CULL_FACE) seperately.

[QUOTE=Agent D;1258049]This is garbage. The constants GL_DEPTH_TEST (0x0B71) and GL_CULL_FACE (0x0B44) are not flags (GL_COLOR_BUFFER_BIT and GL_DEPTH_BUFFER_BIT are, hence the _BIT).
You have to call glEnable(GL_DEPTH_TEST) and glEnable(GL_CULL_FACE) seperately.[/QUOTE]

You are correct of course. I had another bug that i fixed after that.
All works well now. thanks!