Project

General

Profile

« Previous | Next » 

Revision 60036

Test for a long query used in OpenAIRE for spam identification

View differences:

modules/cnr-cql-utils/trunk/src/test/java/eu/dnetlib/functionality/cql/lucene/CqlTranslatorImplTest.java
696 696
		printQuery(cqlQuery, luceneQuery);
697 697
	}
698 698

  
699

  
700
	@Test
701
	public void testSpamQuery() throws IOException, CQLParseException {
702
		String cqlQuery = "\"TUBYDI - Assistir Filmes e Series Online Grátis\" OR\n" +
703
				"\"123Movies\" OR\n" +
704
				"\"WATCH FULL MOVIE\" OR\n" +
705
				"\"Movierulz\" OR\n" +
706
				"resultauthor=\"Full Movie Online\" OR\n" +
707
				"\"MOVIé WatcH\" OR\n" +
708
				"\"The King of Staten Island 2020 Online For Free\" OR\n" +
709
				"\"Watch Train to Busan 2 2020 online for free\" OR\n" +
710
				"\"Sixth Sense Movie Novelization\" OR\n" +
711
				"\"Film Complet streaming vf gratuit en ligne\" OR\n" +
712
				"\"watch now free\" OR\n" +
713
				"(\"LIVE stream\" watch and communityid=*) OR\n" +
714
				"(\"LIVE stream\" watch and collectedfromname=\"Zenodo\") OR\n" +
715
				"(\"LIVE stream\" watch and collectedfromname=\"ZENODO\") oR\n" +
716
				"\"LIVE stream UFC\" OR\n" +
717
				"\"RBC Heritage live stream\" OR\n" +
718
				"\"MLBStreams Free\" OR\n" +
719
				"\"NFL Live Stream\" OR\n" +
720
				"\"Live Stream Free\" OR\n" +
721
				"\"Royal Ascot 2020 Live Stream\" OR\n" +
722
				"resultauthor exact \"TV Shows Full Episodes Official\" OR\n" +
723
				"\"FuboTV\" OR\n" +
724
				"\"Gomovies\" OR\n" +
725
				"\"Online Free Trial Access\" OR\n" +
726
				"\"123watch\" OR\n" +
727
				"(oaftype=result AND \"粽邪2線上看\" ) OR\n" +
728
				"(resultauthor  exact \"DÜŞÜK HAPI\" ) OR\n" +
729
				"\"Bebek  Düşürme Yöntemleri\"  OR\n" +
730
				"resultauthor = \"cytotec düşük hapı\"  OR\n" +
731
				"resultauthor = \"cytotec\"  OR\n" +
732
				"resultauthor = \"Düşük hapı satın al\"  OR\n" +
733
				"\"WHATSAP İLETİŞİM \" OR\n" +
734
				"\"düşük hapı Cytotec\"  OR\n" +
735
				"“粽邪2線上看” OR\n" +
736
				"\"kimetsu no yaiba pelicula completa\" OR\n" +
737
				"\"夺冠线上看\" OR\n" +
738
				"\"消失的情人節線上看\" OR\n" +
739
				"\"夺冠 在线\" OR\n" +
740
				"\"kimetsu no yaiba el tren infinito película completa\" OR\n" +
741
				"\"ver kimetsu no yaiba pelicula el tren infinito\" OR\n" +
742
				"\"夺冠在线\" OR\n" +
743
				"\"馗降粽邪2線上看\" OR\n" +
744
				"\"夺冠完整版\" OR\n" +
745
				"\"刻在你心底的名字线上看\" OR\n" +
746
				"\"düşük hapı\" OR\n" +
747
				"\"夺冠电影在线\" OR\n" +
748
				"\"ocean's 8 pelicula completa en español latino\" OR\n" +
749
				"\"after we collided online sa prevodom\" OR\n" +
750
				"\"馗降粽邪2线上看\" OR\n" +
751
				"\"kimetsu no yaiba pelicula online\"";
752

  
753
		String luceneQuery = translator.toLucene(cqlQuery);
754
		printQuery(cqlQuery, luceneQuery);
755
	}
756

  
699 757
	private void printQuery(final String cql, final String lucene) throws CQLParseException, IOException {
700 758
		System.out.println("CQL:    " + cql);
701 759
		// System.out.println("PARSED: " + new CQLParser().parse(cql).toCQL());

Also available in: Unified diff