summaryrefslogtreecommitdiff
path: root/ext/shmop
diff options
context:
space:
mode:
authorGabriel Caruso <carusogabriel34@gmail.com>2018-09-16 14:16:42 -0300
committerGabriel Caruso <carusogabriel34@gmail.com>2018-10-14 12:07:20 -0300
commit9c144e0d8217d1ef7a83c2498214308b21af749f (patch)
treed977ba0d8601de477c52f62accf02c120ef06253 /ext/shmop
parentb419732ddb0673dc5b15a67ee4bc7f06dd90d7d0 (diff)
downloadphp-git-9c144e0d8217d1ef7a83c2498214308b21af749f.tar.gz
Trim trailing whitespace in tests
Diffstat (limited to 'ext/shmop')
-rw-r--r--ext/shmop/tests/001.phpt26
1 files changed, 13 insertions, 13 deletions
diff --git a/ext/shmop/tests/001.phpt b/ext/shmop/tests/001.phpt
index 5b798cd5ba..a5ad01c302 100644
--- a/ext/shmop/tests/001.phpt
+++ b/ext/shmop/tests/001.phpt
@@ -13,15 +13,15 @@ shmop extension test
$write_d2 = "test #2 append data to shared memory segment";
echo "shm open for create: ";
- $shm_id = shmop_open($hex_shm_id, "n", 0644, 1024);
+ $shm_id = shmop_open($hex_shm_id, "n", 0644, 1024);
if (!$shm_id) {
die("failed\n");
} else {
echo "ok\n";
}
-
+
echo "shm size is: " . ($shm_size = shmop_size($shm_id)) . "\n";
-
+
echo "shm write test #1: ";
$written = shmop_write($shm_id, $write_d1, 0);
if ($written != strlen($write_d1)) {
@@ -29,34 +29,34 @@ shmop extension test
} else {
echo "ok\n";
}
-
+
echo "data in memory is: " . shmop_read($shm_id, 0, $written) . "\n";
shmop_close($shm_id);
-
+
echo "shm open for read only: ";
- $shm_id = shmop_open($hex_shm_id, "a", 0644, 1024);
+ $shm_id = shmop_open($hex_shm_id, "a", 0644, 1024);
if (!$shm_id) {
echo "failed\n";
} else {
echo "ok\n";
}
-
+
echo "data in memory is: " . shmop_read($shm_id, 0, $written) . "\n";
-
+
/* try to append data to the shared memory segment, this should fail */
shmop_write($shm_id, $write_d1, $written);
shmop_close($shm_id);
-
+
echo "shm open for read only: ";
- $shm_id = shmop_open($hex_shm_id, "w", 0644, 1024);
+ $shm_id = shmop_open($hex_shm_id, "w", 0644, 1024);
if (!$shm_id) {
echo "failed\n";
} else {
echo "ok\n";
}
-
+
echo "shm write test #1: ";
$written = shmop_write($shm_id, $write_d2, $written);
if ($written != strlen($write_d2)) {
@@ -64,7 +64,7 @@ shmop extension test
} else {
echo "ok\n";
}
-
+
echo "data in memory is: " . shmop_read($shm_id, 0, strlen($write_d1 . $write_d2)) . "\n";
echo "deletion of shm segment: ";
@@ -73,7 +73,7 @@ shmop extension test
} else {
echo "ok\n";
}
-
+
shmop_close($shm_id);
?>
--EXPECTF--