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

fix: added dummy-test to test git workflow & gitignore file #7

Merged
merged 2 commits into from
Jun 22, 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
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
### Composer ###
composer.phar
/vendor/
composer.lock
6 changes: 1 addition & 5 deletions includes/class-openedx-woocommerce-plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -138,11 +138,7 @@ private function load_dependencies() {
* The class responsible for rendering the enrollment info form
*/
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'admin/views/class-openedx-woocommerce-plugin-enrollment-info-form.php';

/**
* The class responsible for doing the dummy testing
*/
require_once plugin_dir_path( dirname( __FILE__ ) ) . 'test/hello-test.php';

}

/**
Expand Down
23 changes: 9 additions & 14 deletions test/HelloTest.php
Original file line number Diff line number Diff line change
@@ -1,21 +1,16 @@
<?php

class HelloTest extends \PHPUnit\Framework\TestCase {
/**
* This test is a dummy test that always passes.
/**
* This test is a dummy test that always passes.
* It was implemented just to test the Git Workflow
* that implements PHPUnit.
*/
/** @test */
// public function test_hello_test() {
// $expected = true;
// $actual = true;
*/
public function test_hello_test() {
$expected = true;
$actual = true;

// // Assertion
// if ($actual === $expected) {
// echo "Test Passed!";
// } else {
// echo "Test Failed!";
// }
// }
// Assertion
$this->assertTrue($actual === $expected);
}
}