Skip to content

Commit

Permalink
auto merge of #8369 : yichoi/rust/arm-test, r=sanxiyn
Browse files Browse the repository at this point in the history
fix some part of test code to pass make check on ARM Android
  • Loading branch information
bors committed Aug 9, 2013
2 parents 74efdf6 + d463f4c commit c20b906
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion mk/install.mk
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ endef
$(foreach target,$(CFG_TARGET_TRIPLES), \
$(if $(findstring $(target),"arm-linux-androideabi"), \
$(if $(findstring adb,$(CFG_ADB)), \
$(if $(findstring device,$(shell adb devices 2>/dev/null | grep -E '^[_A-Za-z0-9-]+[[:blank:]]+device')), \
$(if $(findstring device,$(shell $(CFG_ADB) devices 2>/dev/null | grep -E '^[_A-Za-z0-9-]+[[:blank:]]+device')), \
$(info install: install-runtime-target for $(target) enabled \
$(info install: android device attached) \
$(eval $(call DEF_ADB_DEVICE_STATUS, true))), \
Expand Down
2 changes: 1 addition & 1 deletion mk/tests.mk
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ endef
$(foreach target,$(CFG_TARGET_TRIPLES), \
$(if $(findstring $(target),"arm-linux-androideabi"), \
$(if $(findstring adb,$(CFG_ADB)), \
$(if $(findstring device,$(shell adb devices 2>/dev/null | grep -E '^[_A-Za-z0-9-]+[[:blank:]]+device')), \
$(if $(findstring device,$(shell $(CFG_ADB) devices 2>/dev/null | grep -E '^[_A-Za-z0-9-]+[[:blank:]]+device')), \
$(info check: $(target) test enabled \
$(info check: android device attached) \
$(eval $(call DEF_ADB_DEVICE_STATUS, true))), \
Expand Down
8 changes: 4 additions & 4 deletions src/libstd/run.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1309,11 +1309,11 @@ mod tests {
let output = str::from_bytes(prog.finish_with_output().output);
let r = os::env();
for &(k, v) in r.iter() {
for &(ref k, ref v) in r.iter() {
// don't check android RANDOM variables
if k != ~"RANDOM" {
assert!(output.contains(fmt!("%s=%s", k, v)) ||
output.contains(fmt!("%s=\'%s\'", k, v)));
if *k != ~"RANDOM" {
assert!(output.contains(fmt!("%s=%s", *k, *v)) ||
output.contains(fmt!("%s=\'%s\'", *k, *v)));
}
}
}
Expand Down

0 comments on commit c20b906

Please sign in to comment.