Relational Databases/Salon Appointment Scheduler

I am working on the Salon Appointment Scheduler (3/5) in the Relational Databases cert, and while I have made the script do everything laid out in the requirements, many of the tests are not passing.

For example:
“If you pick a service that doesn’t exist, you should be shown the same list of services again”
My script does this, but this test does not pass.

here is my project:

I even moved salon.sh and salon.sql out from the salon_app_scheduler folder of my repo and into the projects folder of the assignment, so it should be what the assignment is expecting, but still the tests are not passing.

The db can be rebuilt from salon.sql but you can also just run ./build_db.sh in the terminal as well, before running salon.sh, and everything should work.

Any help is much appreciated!

I am working on the Salon Appointment Scheduler (3/5) in the Relational Databases cert, and while I have made the script do everything laid out in the requirements, many of the tests are not passing.

For example:
“If you pick a service that doesn’t exist, you should be shown the same list of services again”
My script does this, but this test does not pass.

here is my project:

I even moved salon.sh and salon.sql out from the salon_app_scheduler folder of my repo and into the projects folder of the assignment, so it should be what the assignment is expecting, but still the tests are not passing.

The db can be rebuilt from salon.sql but you can also just run ./build_db.sh in the terminal as well, before running salon.sh, and everything should work.

Any help is much appreciated!

Welcome back to the forum @johnbeatrice

Please post the output of your script after selecting a service.

Happy coding

I went ahead and combined your posts for you. In the future, just reply to the original thread to add further updates.

Thanks.

Here is an example

Hi @johnbeatrice

You need to use the same text from the examples.


// Here are two examples of the output of a passing script:

~~~~~ MY SALON ~~~~~

Welcome to My Salon, how can I help you?

1) cut
2) color
3) perm
4) style
5) trim
10

I could not find that service. What would you like today?
1) cut
2) color
3) perm
4) style
5) trim
1

What's your phone number?
555-555-5555

I don't have a record for that phone number, what's your name?
Fabio

What time would you like your cut, Fabio?
10:30

I have put you down for a cut at 10:30, Fabio.


// Next example:

~~~~~ MY SALON ~~~~~

Welcome to My Salon, how can I help you?

1) cut
2) color
3) perm
4) style
5) trim
2

What's your phone number?
555-555-5555

What time would you like your color, Fabio?
11am

I have put you down for a color at 11am, Fabio.

Also, outputting extra text may fail the tests.

I changed the category from freeCodeCamp Support to Backend Development to better reflect the nature of the post.

Happy coding

Okay, thanks for the tips. Here is an example I created, but I’m still not passing some of the basic tests. Any ideas?

Try using the same casing and text from the example for the services.

Okay, I tried that, but the tests still are not passing. Here is a list of the tests that are not passing, as well as an example of the script being run:


What does the final requirement mean?

“Make sure your script finishes running after completing any of the tasks above, or else the tests won’t pass.”

Not sure what they mean by script finishes running? If the script finishes running then the program would close, right?

I notice in your image that color is selected but one of the following questions asks, “What time would you like your cut…?”.

Good catches Teller and fcc4b6d10c4-b540-4e2, thanks for the help, but even after making those changes, all of the same tests are still not passing.

Here are screenshots that show (as far as I can tell) that each of these tests that is NOT passing, SHOULD be passing.
Really scratching my head over this one. Any help is appreciated!

Try with a single line break after the My Salon title.

The same tests are still not passing :frowning:

Try option 2, using phone number 555-555-5555 at 11am

If you look back a few pictures I tried that one as well, the only change i made was to remove 1 line of whitespace.
I am reaching out to support now to see if they can direct me to the actual test code so maybe I can get some hint of what is wrong there

According to this thread I found, it seems that the code for the tests is not public and cannot be viewed by users. That is unfortunate :frowning: