[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/cpio-mode 92481ae 18/61: Create cpio-newc-test.el
From: |
Stefan Monnier |
Subject: |
[elpa] externals/cpio-mode 92481ae 18/61: Create cpio-newc-test.el |
Date: |
Fri, 11 Jan 2019 15:25:23 -0500 (EST) |
branch: externals/cpio-mode
commit 92481ae8697119a79863a6f4bab3577e0500547d
Author: dlewan <address@hidden>
Commit: GitHub <address@hidden>
Create cpio-newc-test.el
Initial code from local CVS.
---
cpio-newc-test.el | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 90 insertions(+)
diff --git a/cpio-newc-test.el b/cpio-newc-test.el
new file mode 100644
index 0000000..1cfce98
--- /dev/null
+++ b/cpio-newc-test.el
@@ -0,0 +1,90 @@
+a;; -*- coding: utf-8 -*-
+;;; cpio-newc-tests.el --- Functions to help test cpio-newc.el
+; $Id: cpio-newc-tests.el,v 1.1.4.5 2018/03/08 06:10:14 doug Exp $
+
+;; COPYRIGHT
+
+;; Copyright © 2015, 2017 Douglas Lewan, address@hidden
+;; All rights reserved.
+;;
+;; This program is free software: you can redistribute it and/or modify
+;; it under the terms of the GNU General Public License as published by
+;; the Free Software Foundation, either version 3 of the License, or
+;; (at your option) any later version.
+;;
+;; This program is distributed in the hope that it will be useful,
+;; but WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;; GNU General Public License for more details.
+;;
+;; You should have received a copy of the GNU General Public License
+;; along with this program. If not, see <http://www.gnu.org/licenses/>.
+;;
+
+;; Author: Douglas Lewan (address@hidden)
+;; Maintainer: -- " --
+;; Created: 2015 Apr 23
+;; Version: 0.01
+;; Keywords: cpio, newc, test
+
+;; (error "You can't actually load cpio-newc-tests.el yet.")
+
+
+;;; Commentary:
+
+;;; Documentation:
+
+;; Right now this is just a text file containing things
+;; for which test code should be written.
+;; It's not even proposing a test harness, just topics.
+
+;; • DONE symbolic mode encoding
+;; • symbolic mode decoding
+;; • DONE (round-up)
+;; • DONE (Full header length) == 0 mod 4.
+;; • header construction then parsing yields the original information.
+;; • (mapcar 'length (cpio-newc-parse-header-at-point))
+;; => (6 8 8 8 8 8 8 8 8 8 8 8 8 8 n)
+;; • (= (length (cpio-newc-header-at-point))
+;; (apply '+ (mapcar 'length (cpio-newc-parse-header-at-point))))
+;; • STARTED (cpio-discern-archive-type)
+
+;;; Code:
+
+;;
+;; Dependencies
+;;
+(require 'ert)
+(require 'cpio-newc)
+
+;;
+;; Vars
+;;
+
+;; MAINTENANCE: The following list of fields denotes the individual fields in
the headers variable.
+(defvar *cpio-newc-header-field-names* ()
+ "An ordered list of the field names of a newc header.")
+(setq *cpio-newc-header-field-names* (list "magic number"
+ "inode"
+ "mode"
+ "uid"
+ "gid"
+
+ "number of links"
+ "modification time"
+ "filesize"
+ "major device"
+ "minor device"
+
+ "major rdev"
+ "minoe rdev"
+ "name size"
+ "checksum"
+ "filename")))
+
+;; MAINTENANCE: See the MAINTENANCE note on *cpio-newc-header-field-names*.
+(defvar headers ()
+ "A list of ( HEADER . PARSED-HEADER ) pairs.
+The HEADER is padded;
+you should strip the trailing NULLS before using it.")
+(setq headers (list (cons
"070701005A0DDD000081A4000003E8000003E800000001567EA4FC000000D5000000FC0000000100000000000000000000000900000000CALENDAR
- [elpa] branch externals/cpio-mode created (now 90f1236), Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 7626f39 01/61: Create README.md, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 8ef4a0e 05/61: Create cpio-bin.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 4d11b71 06/61: Create cpio-crc.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode c0d77ed 04/61: Create cpio-affiliated-buffers.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode e048c6f 02/61: Create configure.ac, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 8cfe789 03/61: Create COPYING, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 339dee9 10/61: Create cpio-entry-header.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 6ef0296 11/61: Create cpio-generic.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 25d2230 09/61: Create cpio-entry-contents-mode.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 92481ae 18/61: Create cpio-newc-test.el,
Stefan Monnier <=
- [elpa] externals/cpio-mode 2463890 14/61: Create cpio-hpodc.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 70755a2 21/61: Create cpio-tests.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 125c509 19/61: Create cpio-odc.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode adc2862 13/61: Create cpio-hpbin.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode e77f48e 16/61: Create cpio-modes-test.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 8011050 20/61: Create cpio-tar.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 12877b1 22/61: Create cpio-ustar.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode 0af3b11 15/61: Create cpio-modes.el, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode bf69494 27/61: Create NEWS, Stefan Monnier, 2019/01/11
- [elpa] externals/cpio-mode e36cab4 23/61: Create cpio-wanted.el, Stefan Monnier, 2019/01/11