 
       restrictedQuery = KodingLogger.generateRestrictedQuery group, query
 
+      identifiers = []
+      for _scope in KodingLogger.SCOPES
+        identifiers.push KodingLogger.getIdentifier _scope, group
+
       expect restrictedQuery
         .to.exist
-        .to.be.equal "([log:apple] OR [error:apple] OR [warn:apple] OR [info:apple]) AND #{query}"
+        .to.be.equal "(#{identifiers.join ' OR '}) AND #{query}"
 
       done()
 


      restrictedQuery = KodingLogger.generateRestrictedQuery group, query

      expect restrictedQuery
        .to.exist
        .to.be.equal "([log:apple] OR [error:apple] OR [warn:apple] OR [info:apple]) AND #{query}"

      done()


          expect(result).to.exist
          expect(result.logs).to.exist
          expect(result.logs).to.have.length.above 0
          expect(result.logs[0].message).to.be.equal "#{identifier} #{log}"

          KodingLogger.close()

