xeluxee / competitest.nvim

CompetiTest.nvim is a Neovim plugin for Competitive Programming: it can manage and check testcases, download problems and contests from online judges and much more
GNU Lesser General Public License v3.0
389 stars 16 forks source link

Is there a way to fetch test cases ? #1

Closed fahimtho closed 2 years ago

fahimtho commented 2 years ago

Some problems have a lot of test cases so making them will take a lot of time. So, if there could be some sort of integration between this plugin and extensions like Competitive Companion it would be the best plugin for cp.

also thanks for this cool plugin.

xeluxee commented 2 years ago

I'm planning to add integration with competitive companion See https://github.com/xeluxee/competitest.nvim#future-plans

p00f commented 2 years ago

@xeluxee you can take a look at my plugin (cphelper.nvim), specifically https://github.com/p00f/cphelper.nvim/blob/main/lua/cphelper/receive.lua and https://github.com/p00f/cphelper.nvim/blob/main/lua/cphelper/prepare.lua.

If competitest gets this feature I'll probably stop maintaining cphelper

xeluxee commented 2 years ago

@p00f thanks for your suggestion, I'll give a look. Also thanks for developing cphelper, a plugin from which I took inspiration to create competitest

At the moment I'm working on another feature (storing testcases in a single file) Soon I'll start working on fetching testcases

xeluxee commented 2 years ago

@fahimfaisal42 @p00f I've just implemented this feature in b9a59ae8260a9d7337cffea5d986afd5f9593b41

Let me know if everything works fine before closing this issue

p00f commented 2 years ago

Works great, thanks

krishnakumarg1984 commented 2 years ago

@p00f Now that this feature is available here, do you plan to stop developing cphelper.nvim?

p00f commented 2 years ago

Not for now 😄

krishnakumarg1984 commented 2 years ago

It would be nice if these two plugins could document the differences with respect to the other. This shall aid the user to make an informed choice about which to install. E.g, see this example for detailed comments by both plugin authors comparing indent-o-matic and guessindent.nvim

Also, do the plugins work with leetcode?

p00f commented 2 years ago

Leetcode uses its own testing - you need to implement methods and they test the object themselves so it's impossible to do it by comparing input/ouput

krishnakumarg1984 commented 2 years ago

@p00f Ok. Understood. May I please request mentioning in your README.md, the CP websites the plugin can work with?

p00f commented 2 years ago

It uses https://github.com/jmerle/competitive-companion and should work with whatever the browser extension supports