strpos(string, sub) returns false if sub is not present in string. In this case, we want to check if sub is not a prefix of string. Hence, we just need to test if the returned position is simply different from 0.
About the test I changed: The test is checking for notes, but 'Bridge Fed' is, in fact, an article according to the post discovery algorithm. Also, I'm adding as note that the main difference between a note and an article is that the latter has a title, while the first doesn't.
strpos(string, sub)
returnsfalse
ifsub
is not present instring
. In this case, we want to check ifsub
is not a prefix ofstring
. Hence, we just need to test if the returned position is simply different from 0.About the test I changed: The test is checking for notes, but 'Bridge Fed' is, in fact, an article according to the post discovery algorithm. Also, I'm adding as note that the main difference between a note and an article is that the latter has a title, while the first doesn't.