Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

more guess tests #145

Merged
merged 3 commits into from
Oct 24, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions test-suite/Guess_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ func TestGuess(t *testing.T) {
"basic",
"dedup",
"nested",
"esparse-fail",
}
}

Expand All @@ -50,6 +51,8 @@ func TestGuess(t *testing.T) {

tests[ext]["py"] = []string{
"basic",
"dedup",
"replit-packages",
}
}

Expand Down
7 changes: 7 additions & 0 deletions test-suite/templates/guess/js/esparse-fail
ryantm marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import express from 'express';

const foo = ({
// esparse fails to parse the default argument here,
// resulting in the full guess failing
bar = () => { },
}) => { };
1 change: 1 addition & 0 deletions test-suite/templates/guess/js/esparse-fail.expect
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
express
3 changes: 3 additions & 0 deletions test-suite/templates/guess/py/basic
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from django.shortcuts import render
from flask import Flask
import replit.ai
3 changes: 3 additions & 0 deletions test-suite/templates/guess/py/basic.expect
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
django
flask
replit-ai
4 changes: 4 additions & 0 deletions test-suite/templates/guess/py/dedup
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import django
from django.conf import settings
from django.shortcuts import render
from flask import Flask
2 changes: 2 additions & 0 deletions test-suite/templates/guess/py/dedup.expect
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
django
flask
2 changes: 2 additions & 0 deletions test-suite/templates/guess/py/replit-packages
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
import replit
import replit.ai
2 changes: 2 additions & 0 deletions test-suite/templates/guess/py/replit-packages.expect
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
replit
replit-ai