blob: a917a9b0edb222fabe61e6c000fbee400a8cfcf0 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
// Copyright Vespa.ai. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
package com.yahoo.prelude.semantics.test;
import org.junit.jupiter.api.Test;
/**
* Test a case reported by Alibaba
*
* @author bratseth
*/
public class AlibabaTestCase extends RuleBaseAbstractTestCase {
public AlibabaTestCase() {
super("alibaba.sr");
}
@Test
void testNumberReplacement() {
assertSemantics("AND nokia 3100", "3100");
}
@Test
void testRuleFollowingNumber() {
assertSemantics("lenovo", "legend");
}
@Test
void testCombinedNumberAndRegular1() {
assertSemantics("AND lenovo nokia 3100", "legend 3100");
}
@Test
void testCombinedNumberAndRegular2() {
assertSemantics("AND nokia 3100 lenovo", "3100 legend");
}
}
|