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

Add unit tests #40

Open
sahildua2305 opened this issue Aug 22, 2016 · 14 comments
Open

Add unit tests #40

sahildua2305 opened this issue Aug 22, 2016 · 14 comments

Comments

@sahildua2305
Copy link
Owner

No description provided.

@yemarnevets
Copy link

Hi sahidula, What is an endpoint in this context? I am looking to get involved with open source projects but I am still quite new. I am very familiar with Git, so version control shouldn't be an issue. Can you please point me in the right direction for getting started with adding unittests for this project? Thanks.

@mananpal1997
Copy link
Contributor

@yemarnevets Just check for 2xx, 4xx and 5xx response, if any, from the HackerEarth API for some sample input.
@sahildua2305 Am I right?

@sahildua2305
Copy link
Owner Author

I'm not sure @mananpal1997

Probably what I wanted is to write tests to ensure quality of this project not for validation of HackerEarth's API validation. We should have tests in this project so that we can make sure new contributions aren't breaking anything. I'd encourage you to research on this a bit with @yemarnevets regarding what will be the best way to implement this.

@sahildua2305
Copy link
Owner Author

@mananpal1997 @yemarnevets Any update on this?

@sahildua2305 sahildua2305 changed the title Add unit tests for endpoints Add unit tests Nov 14, 2016
@aboglioli
Copy link

If a make some time, I will collaborate with unit testing 😀

@sahildua2305
Copy link
Owner Author

@aboglioli That'd be great! Let me know if you need help

@cnguy
Copy link

cnguy commented Jan 11, 2017

@sahildua2305 Hello, can I give this a try?

@sahildua2305
Copy link
Owner Author

@ChauTNguyen Sure 🙂

@cnguy
Copy link

cnguy commented Jan 11, 2017

@sahildua2305

https://gist.github.com/ChauTNguyen/13ebafa8ea4f450ce40575bca3f78034

Hi, I'm working on it. However, I wanted to know if I'm starting it out correctly/heading in the right direction, so I wrote just a few basic unit tests.

dependencies: selenium 3.0.2

I started out by covering:

  • loading the site, and compiling to see if the UI and compiling the default works properly (ex: Compile Status: OK)
  • loading the site, and giving failing input to see if the UI works properly (ex: Compile Status: --)
  • turning on the checkbox should add the custom input display, which allows the user to send in custom input. user dumps some input in, and after running the code, the custom input should then be re-displayed within stdin.
  • user does a simple hello world program and runs the program to get a link to the saved code. user then goes to that link (and I tested if the input stays the same) and runs the code, and the output should contain the hello world

I used sleep commands for the short compiles and refreshes (to give DOM time to render).

@sahildua2305
Copy link
Owner Author

@ChauTNguyen looks good. Can you please create a PR for the same?

@PrathameshPalaskar
Copy link

Hello, I am new to open source. Can I contribute to issue #44 ?

@sahildua2305
Copy link
Owner Author

@PrathameshPalaskar welcome. Thanks for showing interest to contribute to this project.

As you can see there's already a pull request for this issue. Do you have any extra ideas about how you would want to do this?

@sahildua2305
Copy link
Owner Author

Re-opening this because the PR #44 was never submitted and this is likely up for grabs.

@sahildua2305 sahildua2305 reopened this Oct 18, 2020
@arvind2221994
Copy link

Is this issue still open? I would like to contribute with some unit tests.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants