Skip to content

Commit

Permalink
test: Update test case
Browse files Browse the repository at this point in the history
  • Loading branch information
jpedroh committed Nov 25, 2023
1 parent 036bcee commit dd175c7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions bin/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ fn main() {
"#;
let left = r#"
public class Main {
void delete(Pessoa pessoa);
void create(Pessoa pessoa);
public static void main(String[] args) {
int x = 0;
Expand All @@ -40,6 +41,7 @@ fn main() {
"#;
let right = r#"
public class Main {
void upsert(Pessoa pessoa);
public static void main(String[] args) {
System.out.println("Hello, Paulo!");
int y = 5;
Expand Down
2 changes: 1 addition & 1 deletion bin/tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,6 @@ use predicates::prelude::*;
#[test]
fn it_does_not_crash_and_produces_the_expected_output() {
let mut cmd = Command::cargo_bin("generic-merge").unwrap();
let predicate_fn = predicate::str::contains(" public class Main { void create ( Pessoa pessoa ) ; public static void main ( String [ ] args ) { int x = 0 ; System . out . println ( <<<<<<<<< \"Hello, João!\" ========= \"Hello, Paulo!\" >>>>>>>>> ) ; int y = <<<<<<<<< 3 ========= 5 >>>>>>>>> ; } }");
let predicate_fn = predicate::str::contains("public class Main { void delete ( Pessoa pessoa ) ; void create ( Pessoa pessoa ) ; public static void main ( String [ ] args ) { int x = 0 ; System . out . println ( <<<<<<<<< \"Hello, João!\" ========= \"Hello, Paulo!\" >>>>>>>>> ) ; int y = <<<<<<<<< 3 ========= 5 >>>>>>>>> ; } void upsert ( Pessoa pessoa ) ; }");
cmd.assert().stdout(predicate_fn);
}

0 comments on commit dd175c7

Please sign in to comment.