or run

tessl search
Log in

Version

Files

tile.json

rubric.jsonevals/scenario-8/

{
  "context": "This criteria evaluates how well the engineer uses micromatch's partial/substring matching capability (micromatch.contains) to filter file paths. The focus is on correctly leveraging the contains function to check if patterns match any part of the path string, rather than implementing custom substring or pattern matching logic.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Uses micromatch.contains",
      "description": "Implementation uses the micromatch.contains() function to check if a pattern matches any part of a path string, rather than implementing custom substring matching or using basic string methods like .includes().",
      "max_score": 50
    },
    {
      "name": "Correct function signature",
      "description": "The micromatch.contains() function is called with correct parameters: contains(string, pattern, options). The string is the path being tested, and the pattern is the search pattern.",
      "max_score": 15
    },
    {
      "name": "Filters array properly",
      "description": "Implementation correctly iterates over the paths array and applies the contains check to each path, returning only paths where contains returns true. Uses appropriate array methods like .filter().",
      "max_score": 15
    },
    {
      "name": "Handles both literals and globs",
      "description": "The solution works correctly for both literal substring patterns (e.g., 'Header', 'api') and glob patterns (e.g., '*.tsx', 'app/**') without requiring separate logic branches, leveraging micromatch.contains's built-in support for both.",
      "max_score": 20
    }
  ]
}