<p>I have a flag enum below.</p>

<pre><code>[Flags]
public enum FlagTest
{
    None = 0x0,
    Flag1 = 0x1,
    Flag2 = 0x2,
    Flag3 = 0x4
}
</code></pre>

<p>I cannot make the if statement evaluate to true.</p>

<pre><code>FlagTest testItem = FlagTest.Flag1 | FlagTest.Flag2;

if (testItem == FlagTest.Flag1)
{
    // Do something,
    // however This is never true.
}
</code></pre>

<p>How can I make this true?</p>

For bit operations, you need to use bitwise operators.
This should do the trick:
```
```
if ((testItem & FlagTest.Flag1) == FlagTest.Flag1)
{
    // Do something,
    // however This is never true.
}
```
```
Edit:
Fixed my if check - I slipped back into my C/C++ ways (thanks to Ryan Farley for pointing it out)